/* =====================================================
   موقع قسم الحسابات الآمنة - شركة الأماني
   تصميم: احترافي - متجاوب - RTL
   ===================================================== */

:root {
    --primary: #0d1b46;
    --primary-light: #1e3a8a;
    --secondary: #005a9e;
    --accent: #00b8d9;
    --accent-2: #f59e0b;
    --gold: #d4af37;
    --dark: #0f172a;
    --gray-100: #f8fafc;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-500: #64748b;
    --gray-700: #334155;
    --gray-900: #0f172a;
    --white: #ffffff;
    --success: #10b981;
    --danger: #ef4444;
    --gradient-primary: linear-gradient(135deg, #0d1b46 0%, #005a9e 50%, #00b8d9 100%);
    --gradient-gold: linear-gradient(135deg, #d4af37 0%, #f59e0b 100%);
    --shadow-sm: 0 2px 8px rgba(13, 27, 70, 0.08);
    --shadow-md: 0 6px 20px rgba(13, 27, 70, 0.1);
    --shadow-lg: 0 12px 40px rgba(13, 27, 70, 0.15);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --transition: all 0.3s ease;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Cairo', 'Tajawal', sans-serif;
    color: var(--gray-700);
    line-height: 1.8;
    background-color: var(--white);
    direction: rtl;
    text-align: right;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Cairo', sans-serif;
    color: var(--gray-900);
    font-weight: 700;
    line-height: 1.4;
}

a {
    color: var(--secondary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--accent);
}

img {
    max-width: 100%;
    height: auto;
}

/* =================== TOP BAR =================== */
.top-bar {
    background: var(--gradient-primary);
    color: rgba(255, 255, 255, 0.9);
    padding: 8px 0;
    font-size: 14px;
}

.top-info a, .top-info span {
    color: rgba(255, 255, 255, 0.9);
    margin-left: 18px;
    text-decoration: none;
    font-size: 14px;
}

.top-info a:hover {
    color: var(--accent-2);
}

.top-info i {
    margin-left: 5px;
    color: var(--accent);
}

.top-social {
    text-align: left;
}

.top-social a {
    color: rgba(255, 255, 255, 0.85);
    width: 32px;
    height: 32px;
    line-height: 32px;
    display: inline-block;
    text-align: center;
    margin: 0 3px;
    border-radius: 50%;
    transition: var(--transition);
}

.top-social a:hover {
    background: var(--accent);
    color: var(--white);
    transform: translateY(-3px);
}

.top-install-btn {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    background: var(--accent) !important;
    color: var(--white) !important;
    border-radius: 50px;
    padding: 6px 14px !important;
    width: auto !important;
    height: auto !important;
    line-height: 1.4 !important;
    font-weight: 700;
    font-size: 13px;
    margin-left: 10px;
    text-decoration: none;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

.top-install-btn:hover {
    background: var(--white) !important;
    color: var(--primary) !important;
    transform: translateY(-2px);
}

/* =================== NAVBAR =================== */
.main-navbar {
    background: var(--white);
    box-shadow: var(--shadow-sm);
    padding: 12px 0;
    transition: var(--transition);
}

.main-navbar > .container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.pwa-install-chip {
    display: inline-flex !important;
    align-items: center;
    gap: 7px;
    background: linear-gradient(135deg, var(--accent), var(--secondary)) !important;
    color: #fff !important;
    border-radius: 50px;
    padding: 9px 16px;
    font-weight: 800;
    font-size: 14px;
    text-decoration: none !important;
    flex-shrink: 0;
    box-shadow: 0 4px 14px rgba(0, 184, 217, 0.35);
    white-space: nowrap;
    order: 2;
    z-index: 5;
}

.pwa-install-chip:hover {
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0, 184, 217, 0.45);
}

.pwa-install-chip i {
    animation: navIconPulse 1.6s ease-in-out infinite;
}

@media (min-width: 992px) {
    .main-navbar .navbar-toggler {
        order: 4;
    }

    .main-navbar .navbar-collapse {
        order: 3;
        flex: 1 1 auto;
    }

    .pwa-install-chip {
        order: 2;
        margin-inline-start: auto;
        margin-inline-end: 12px;
    }
}

@media (max-width: 991.98px) {
    .pwa-install-chip {
        order: 2;
        margin-inline-start: auto;
        margin-inline-end: 8px;
        padding: 8px 12px;
        font-size: 13px;
    }

    .main-navbar .navbar-toggler {
        order: 3;
    }

    .main-navbar .navbar-collapse {
        order: 4;
        width: 100%;
    }
}

.main-navbar.scrolled {
    box-shadow: var(--shadow-md);
    padding: 8px 0;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
}

.logo-img {
    height: 50px;
    width: auto;
    object-fit: contain;
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand-name {
    font-size: 18px;
    font-weight: 800;
    color: var(--primary);
}

.brand-tagline {
    font-size: 12px;
    color: var(--gray-500);
    font-weight: 400;
}

.main-navbar .nav-link {
    color: var(--gray-700) !important;
    font-weight: 600;
    padding: 10px 16px !important;
    margin: 0 2px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    font-size: 15px;
}

.main-navbar .nav-link i {
    margin-left: 6px;
    font-size: 14px;
}

.main-navbar .nav-link:hover,
.main-navbar .nav-link.active {
    color: var(--secondary) !important;
    background: rgba(0, 90, 158, 0.08);
}

.main-navbar .nav-link.active {
    color: var(--primary) !important;
    background: rgba(0, 184, 217, 0.12);
}

.search-form {
    margin-right: 12px;
    align-items: center;
}

.search-form .form-control {
    border-radius: 50px 0 0 50px;
    border: 1px solid var(--gray-200);
    border-left: none;
    width: 155px;
    height: 42px;
    padding-right: 18px;
    background: var(--gray-100);
    box-shadow: none;
    transition: var(--transition);
}

.search-form .form-control:focus {
    background: var(--white);
    border-color: var(--accent);
    box-shadow: 0 0 0 0.18rem rgba(0, 184, 217, 0.15);
}

.btn-search {
    background: var(--secondary);
    color: var(--white);
    border-radius: 0 50px 50px 0;
    border: none;
    width: 46px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.btn-search:hover {
    background: var(--primary);
    color: var(--white);
}

/* زر تسجيل الدخول وقائمة الحساب */
@media (min-width: 992px) {
    .main-navbar .navbar-nav {
        align-items: center;
        flex-wrap: wrap;
        justify-content: flex-end;
        row-gap: 6px;
    }

    .main-navbar .nav-item-install {
        flex-shrink: 0;
    }
}

@keyframes navIconPulse {
    0%   { transform: scale(1); }
    50%  { transform: scale(1.25); }
    100% { transform: scale(1); }
}

.main-navbar .nav-link i {
    display: inline-block;
    transition: var(--transition);
}

.main-navbar .nav-link:hover i,
.main-navbar .nav-link.active i {
    animation: navIconPulse 0.9s ease-in-out infinite;
}

.main-navbar .nav-link.nav-login-link i {
    animation: navIconPulse 1.6s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
    .main-navbar .nav-link i,
    .main-navbar .nav-link.nav-login-link i {
        animation: none !important;
    }
}

.main-navbar .nav-link.nav-login-link {
    background: var(--secondary);
    color: var(--white) !important;
    border-radius: 50px;
    padding: 9px 22px !important;
    margin-right: 6px;
    box-shadow: 0 4px 12px rgba(0, 90, 158, 0.25);
}

.main-navbar .nav-link.nav-login-link:hover {
    background: var(--primary);
    color: var(--white) !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(13, 27, 70, 0.3);
}

.main-navbar .nav-link.nav-account-link {
    background: var(--gray-100);
    color: var(--primary) !important;
    border: 1px solid var(--gray-200);
    border-radius: 50px;
    padding: 7px 18px !important;
    margin-right: 6px;
    font-weight: 700;
}

.main-navbar .nav-link.nav-account-link:hover {
    background: rgba(0, 184, 217, 0.08);
    border-color: var(--accent);
    color: var(--primary) !important;
}

.main-navbar .nav-link.nav-install-link {
    background: linear-gradient(135deg, var(--accent), var(--secondary));
    color: var(--white) !important;
    border-radius: 50px;
    padding: 8px 16px !important;
    margin-right: 4px;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0, 184, 217, 0.28);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.main-navbar .nav-link.nav-install-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 184, 217, 0.4);
    color: var(--white) !important;
}

.main-navbar .nav-link.nav-install-link i {
    animation: navIconPulse 1.6s ease-in-out infinite;
}

.dropdown-menu {
    border: none;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    padding: 8px;
    margin-top: 10px !important;
}

.dropdown-menu .dropdown-item {
    border-radius: var(--radius-sm);
    padding: 9px 14px;
    font-weight: 600;
    font-size: 14px;
}

.dropdown-menu .dropdown-item i {
    margin-left: 8px;
    width: 16px;
    text-align: center;
}

.dropdown-menu .dropdown-item:hover {
    background: rgba(0, 90, 158, 0.08);
    color: var(--secondary);
}

.dropdown-menu .dropdown-item.text-danger:hover {
    background: rgba(239, 68, 68, 0.08);
    color: var(--danger);
}

/* =================== HERO =================== */
.hero-section {
    position: relative;
    background-size: cover;
    background-position: center;
    color: var(--white);
    padding: 100px 0 160px;
    overflow: hidden;
}

.min-vh-75 {
    min-height: 70vh;
}

.hero-particles::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(0, 184, 217, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(245, 158, 11, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.hero-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 14px;
    margin-bottom: 25px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--white);
}

.hero-badge i {
    color: var(--accent-2);
    margin-left: 6px;
}

.hero-title {
    font-size: 56px;
    font-weight: 900;
    color: var(--white);
    line-height: 1.2;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
    font-size: 20px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 35px;
    line-height: 1.7;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 50px;
}

.hero-stats {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 36px;
    font-weight: 800;
    color: var(--accent-2);
    line-height: 1;
}

.stat-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 5px;
}

.hero-illustration {
    text-align: center;
    position: relative;
}

.hero-icon-bg {
    font-size: 280px;
    color: rgba(255, 255, 255, 0.08);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

.hero-wave {
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    line-height: 0;
}

.hero-wave svg {
    width: 100%;
    height: 100px;
}

/* =================== BUTTONS =================== */
.btn-primary-custom {
    background: var(--gradient-primary);
    color: var(--white);
    padding: 12px 30px;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    transition: var(--transition);
    box-shadow: 0 8px 20px rgba(13, 27, 70, 0.25);
}

.btn-primary-custom:hover {
    transform: translateY(-3px);
    color: var(--white);
    box-shadow: 0 12px 30px rgba(13, 27, 70, 0.35);
    filter: brightness(1.1);
}

.btn-primary-custom i {
    margin-left: 8px;
}

.btn-outline-light {
    border: 2px solid rgba(255, 255, 255, 0.7);
    padding: 10px 28px;
    border-radius: 50px;
    font-weight: 600;
    color: var(--white);
}

.btn-outline-light:hover {
    background: var(--white);
    color: var(--primary) !important;
}

/* =================== FEATURES =================== */
.features-section {
    padding: 80px 0;
    background: var(--white);
    margin-top: -80px;
    position: relative;
    z-index: 2;
}

.feature-box {
    background: var(--white);
    padding: 35px 25px;
    text-align: center;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    height: 100%;
    border-bottom: 4px solid transparent;
}

.feature-box:hover {
    transform: translateY(-10px);
    border-bottom-color: var(--accent);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    width: 80px;
    height: 80px;
    line-height: 80px;
    margin: 0 auto 20px;
    background: var(--gradient-primary);
    color: var(--white);
    font-size: 32px;
    border-radius: 50%;
    transition: var(--transition);
}

.feature-box:hover .feature-icon {
    transform: rotateY(180deg);
}

.feature-box h5 {
    color: var(--primary);
    margin-bottom: 12px;
    font-weight: 700;
}

.feature-box p {
    color: var(--gray-500);
    font-size: 14px;
    margin: 0;
}

/* =================== SECTIONS =================== */
.section-heading {
    margin-bottom: 50px;
}

.section-subtitle {
    color: var(--accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 14px;
    display: inline-block;
    margin-bottom: 12px;
    position: relative;
    padding: 0 20px;
}

.section-subtitle::before,
.section-subtitle::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 30px;
    height: 2px;
    background: var(--accent);
}

.section-subtitle::before { right: -20px; }
.section-subtitle::after { left: -20px; }

.section-heading.text-center .section-subtitle::before { right: 50%; transform: translateX(50%) translateX(60px); }
.section-heading.text-center .section-subtitle::after { left: 50%; transform: translateX(-50%) translateX(-60px); }

.section-title {
    font-size: 38px;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 15px;
}

.section-description {
    font-size: 17px;
    color: var(--gray-500);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.8;
}

/* =================== ABOUT =================== */
.about-section {
    padding: 100px 0;
    background: var(--gray-100);
}

.about-image-wrap {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.about-image {
    width: 100%;
    height: 480px;
    object-fit: cover;
}

.about-experience {
    position: absolute;
    bottom: 30px;
    right: 30px;
    background: var(--gradient-primary);
    color: var(--white);
    padding: 20px 30px;
    border-radius: var(--radius-md);
    text-align: center;
    box-shadow: var(--shadow-md);
}

.exp-number {
    display: block;
    font-size: 42px;
    font-weight: 900;
    color: var(--accent-2);
    line-height: 1;
}

.exp-text {
    display: block;
    font-size: 14px;
    margin-top: 5px;
}

.about-content {
    color: var(--gray-700);
    font-size: 16px;
    line-height: 1.9;
}

.about-content p {
    margin-bottom: 16px;
}

.mission-box {
    background: var(--white);
    padding: 25px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border-right: 4px solid var(--accent);
    transition: var(--transition);
    height: 100%;
}

.mission-box:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.mission-box h5 {
    color: var(--primary);
    margin-bottom: 12px;
}

.mission-box h5 i {
    color: var(--accent);
    margin-left: 8px;
}

.mission-box p {
    color: var(--gray-500);
    font-size: 14px;
    margin: 0;
}

.mission-box-large {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    text-align: center;
    height: 100%;
    transition: var(--transition);
}

.mission-box-large:hover {
    transform: translateY(-8px);
}

.mission-box-large i {
    font-size: 48px;
    color: var(--accent);
    margin-bottom: 20px;
    background: rgba(0, 184, 217, 0.1);
    width: 90px;
    height: 90px;
    line-height: 90px;
    border-radius: 50%;
    display: inline-block;
}

.mission-box-large h4 {
    color: var(--primary);
    margin-bottom: 15px;
}

/* =================== SERVICES =================== */
.services-section {
    padding: 100px 0;
    background: var(--white);
}

.service-card {
    background: var(--white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
    border: 1px solid var(--gray-200);
}

.service-card:hover {
    transform: translateY(-12px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent);
}

.service-card-image {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* شارة "الأكثر طلبًا" */
.popular-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: linear-gradient(135deg, #ff512f, #dd2476);
    color: #fff;
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 800;
    box-shadow: 0 4px 12px rgba(221, 36, 118, 0.4);
    animation: popularPulse 1.8s ease-in-out infinite;
}

.popular-badge i {
    color: #ffe08a;
}

@keyframes popularPulse {
    0%, 100% { transform: scale(1); box-shadow: 0 4px 12px rgba(221, 36, 118, 0.4); }
    50% { transform: scale(1.06); box-shadow: 0 6px 18px rgba(221, 36, 118, 0.6); }
}

@media (prefers-reduced-motion: reduce) {
    .popular-badge { animation: none; }
}

.service-card-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    display: block;
    background: var(--white);
    transition: var(--transition);
}

.service-card:hover .service-card-image img {
    transform: scale(1.1);
}

.service-icon-wrap {
    font-size: 52px;
    color: rgba(255, 255, 255, 0.9);
}

.service-overlay {
    position: absolute;
    inset: 0;
    background: rgba(13, 27, 70, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.service-card:hover .service-overlay {
    opacity: 1;
}

.btn-overlay {
    width: 60px;
    height: 60px;
    line-height: 60px;
    background: var(--accent-2);
    color: var(--white);
    border-radius: 50%;
    text-align: center;
    font-size: 22px;
    transition: var(--transition);
}

.btn-overlay:hover {
    background: var(--white);
    color: var(--primary);
    transform: rotate(45deg);
}

.service-card-body {
    padding: 22px 20px 20px;
    position: relative;
}

.service-icon-small {
    width: 52px;
    height: 52px;
    line-height: 44px;
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: 50%;
    text-align: center;
    font-size: 18px;
    position: absolute;
    top: -26px;
    right: 25px;
    box-shadow: 0 6px 18px rgba(0, 90, 158, 0.35);
    border: 4px solid #00c2cb;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
}

.service-card:hover .service-icon-small {
    transform: translateY(-3px) rotate(8deg) scale(1.08);
    border-color: #ffb703;
    box-shadow: 0 8px 22px rgba(255, 183, 3, 0.45);
}

.service-title {
    margin-top: 8px;
    margin-bottom: 10px;
    font-size: 17px;
    font-weight: 700;
}

.service-title a {
    color: var(--primary);
}

.service-title a:hover {
    color: var(--accent);
}

.service-description {
    color: var(--gray-500);
    font-size: 13px;
    line-height: 1.7;
    margin-bottom: 14px;
}

.service-link {
    color: var(--accent);
    font-weight: 600;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.service-link:hover {
    color: var(--primary);
    gap: 14px;
}

/* =================== CTA =================== */
.cta-section {
    padding: 80px 0;
    background: var(--gray-100);
}

.cta-box {
    background: var(--gradient-primary);
    color: var(--white);
    padding: 50px 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.cta-box::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
}

.cta-box h3 {
    color: var(--white);
    font-size: 28px;
    margin-bottom: 10px;
    position: relative;
}

.cta-box p {
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    position: relative;
}

.btn-light {
    background: var(--white);
    color: var(--primary);
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 700;
    border: none;
}

.btn-light:hover {
    background: var(--accent-2);
    color: var(--white);
}

/* =================== GOALS =================== */
.goals-section {
    padding: 100px 0;
    background: var(--white);
}

.goal-item {
    background: var(--white);
    padding: 30px 25px 25px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    text-align: center;
    height: 100%;
    transition: var(--transition);
    border-top: 4px solid var(--accent);
}

.goal-item:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-md);
}

.goal-number {
    width: 60px;
    height: 60px;
    line-height: 60px;
    background: var(--gradient-gold);
    color: var(--white);
    border-radius: 50%;
    margin: 0 auto 18px;
    font-size: 22px;
    font-weight: 800;
}

.goal-item p {
    color: var(--gray-700);
    font-size: 16px;
    margin: 0;
}

/* =================== PAGE HEADER =================== */
.page-header {
    background: var(--gradient-primary);
    color: var(--white);
    padding: 80px 0 60px;
    text-align: center;
    position: relative;
}

.page-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100" preserveAspectRatio="none"><polygon fill="rgba(255,255,255,0.03)" points="0,0 100,0 100,30 0,80"/></svg>');
    background-size: cover;
    pointer-events: none;
}

.page-header h1 {
    color: var(--white);
    font-size: 42px;
    font-weight: 800;
    margin-bottom: 15px;
    position: relative;
}

.page-header .breadcrumb {
    background: transparent;
    margin: 0;
    position: relative;
}

.page-header .breadcrumb a {
    color: rgba(255, 255, 255, 0.8);
}

.page-header .breadcrumb a:hover {
    color: var(--accent-2);
}

.page-header .breadcrumb-item.active {
    color: var(--accent-2);
}

.page-header .breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.5);
    content: "/";
}

/* =================== SERVICE DETAIL =================== */
.service-detail-section {
    padding: 80px 0;
    background: var(--gray-100);
}

.service-detail-content {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.service-detail-image {
    margin-bottom: 30px;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.service-detail-icon {
    text-align: center;
    padding: 60px 0;
    background: var(--gradient-primary);
    border-radius: var(--radius-md);
    margin-bottom: 30px;
}

.service-detail-icon i {
    font-size: 80px;
    color: var(--white);
}

.service-meta {
    display: flex;
    gap: 25px;
    flex-wrap: wrap;
    color: var(--gray-500);
    font-size: 14px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--gray-200);
}

.service-meta-item i {
    margin-left: 6px;
    color: var(--accent);
}

.service-detail-title {
    font-size: 32px;
    color: var(--primary);
    margin-bottom: 15px;
}

.service-detail-short {
    font-size: 18px;
    color: var(--gray-700);
    background: rgba(0, 184, 217, 0.08);
    padding: 18px 22px;
    border-right: 4px solid var(--accent);
    border-radius: var(--radius-sm);
    margin-bottom: 25px;
}

.service-detail-body {
    line-height: 1.9;
    font-size: 16px;
    color: var(--gray-700);
    margin-bottom: 30px;
}

.service-detail-body p { margin-bottom: 16px; }

.service-features-block,
.service-projects-block {
    margin-top: 35px;
    padding-top: 30px;
    border-top: 1px solid var(--gray-200);
}

.service-features-block h3,
.service-projects-block h3 {
    color: var(--primary);
    margin-bottom: 22px;
    font-size: 22px;
}

.service-features-block h3 i,
.service-projects-block h3 i {
    color: var(--accent-2);
    margin-left: 8px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    background: var(--gray-100);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.feature-item:hover {
    background: rgba(0, 184, 217, 0.1);
    transform: translateX(-5px);
}

.feature-item i {
    color: var(--success);
    font-size: 20px;
}

.project-type-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.project-type-item:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-sm);
}

.project-type-num {
    width: 32px;
    height: 32px;
    line-height: 32px;
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: 50%;
    text-align: center;
    font-weight: 700;
    flex-shrink: 0;
}

.service-cta {
    margin-top: 40px;
    padding: 35px;
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: var(--radius-md);
    text-align: center;
}

.service-cta h3 {
    color: var(--white);
    margin-bottom: 8px;
}

.service-cta p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 20px;
}

/* =================== SIDEBAR =================== */
.service-sidebar {
    position: sticky;
    top: 100px;
}

.sidebar-widget {
    background: var(--white);
    padding: 25px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    margin-bottom: 25px;
}

.contact-widget {
    background: var(--gradient-primary);
    color: var(--white);
}

.contact-widget h4,
.contact-widget p {
    color: var(--white);
}

.contact-widget h4 i {
    margin-left: 8px;
    color: var(--accent-2);
}

.btn-block {
    display: block;
    margin-bottom: 8px;
}

.sidebar-title {
    color: var(--primary);
    margin-bottom: 18px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
}

.sidebar-services {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-services li {
    border-bottom: 1px solid var(--gray-200);
}

.sidebar-services li:last-child { border-bottom: none; }

.sidebar-services a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    color: var(--gray-700);
    transition: var(--transition);
}

.sidebar-services a:hover {
    color: var(--accent);
    padding-right: 8px;
}

.sidebar-services .arrow {
    margin-right: auto;
    font-size: 12px;
    opacity: 0.5;
}

/* =================== CONTACT =================== */
.contact-section {
    padding: 80px 0;
    background: var(--gray-100);
}

.contact-info-card {
    background: var(--white);
    padding: 35px 25px;
    border-radius: var(--radius-md);
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
}

.contact-info-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-md);
}

.contact-info-icon {
    width: 80px;
    height: 80px;
    line-height: 80px;
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: 50%;
    margin: 0 auto 20px;
    font-size: 30px;
}

.contact-info-card h5 {
    color: var(--primary);
    margin-bottom: 8px;
}

.contact-info-card a,
.contact-info-card p {
    color: var(--gray-700);
    margin: 0;
    font-size: 15px;
}

.contact-form-wrap {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

/* استمارة طلب موقع / خدمة (فورما) */
.request-form-wrap {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    border-top: 5px solid var(--accent);
}

.request-form-head {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 22px;
}

.request-form-icon {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    color: var(--white);
    background: linear-gradient(135deg, var(--accent), var(--secondary));
    box-shadow: 0 6px 16px rgba(0, 184, 217, 0.3);
}

.request-form-head h3 {
    color: var(--primary);
    font-weight: 800;
}

.request-note {
    background: rgba(0, 184, 217, 0.08);
    border: 1px dashed var(--accent);
    color: var(--secondary);
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    margin-bottom: 22px;
    font-weight: 600;
    font-size: 14px;
}

.request-note i {
    margin-left: 6px;
}

/* اختيار الألوان */
.color-picker {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.color-swatch {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--white);
    border: 1.5px solid var(--gray-200);
    border-radius: 50px;
    padding: 5px 12px 5px 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    cursor: pointer;
    transition: var(--transition);
}

.color-swatch .color-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--sw);
    border: 1px solid rgba(0, 0, 0, 0.15);
    flex-shrink: 0;
}

.color-swatch:hover {
    border-color: var(--accent);
    transform: translateY(-1px);
}

.color-swatch.selected {
    border-color: var(--secondary);
    background: rgba(0, 90, 158, 0.08);
    color: var(--primary);
    box-shadow: 0 0 0 2px rgba(0, 184, 217, 0.2);
}

.color-swatch.selected::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 10px;
    color: var(--secondary);
    margin-right: 2px;
}

@media (max-width: 575.98px) {
    .request-form-wrap { padding: 24px; }
    .request-form-head { flex-direction: row; }
    .request-form-icon { width: 48px; height: 48px; font-size: 20px; }
}

.contact-form-wrap h3 {
    color: var(--primary);
    margin-bottom: 5px;
}

.form-label {
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.form-control,
.form-select {
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0, 184, 217, 0.15);
}

.contact-side {
    background: var(--gradient-primary);
    color: var(--white);
    padding: 40px;
    border-radius: var(--radius-md);
    height: 100%;
}

.contact-side h3 {
    color: var(--white);
    margin-bottom: 12px;
}

.contact-side p {
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 30px;
}

.contact-side-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.contact-side-list li {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.contact-side-list li:last-child { border-bottom: none; }

.contact-side-list i {
    width: 45px;
    height: 45px;
    line-height: 45px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    text-align: center;
    color: var(--accent-2);
    flex-shrink: 0;
}

.contact-side-list strong {
    display: block;
    color: var(--white);
    margin-bottom: 4px;
}

.contact-side-list a,
.contact-side-list span {
    color: rgba(255, 255, 255, 0.9);
}

.contact-side-list a:hover {
    color: var(--accent-2);
}

/* =================== FOOTER =================== */
.site-footer {
    background: var(--dark);
    color: rgba(255, 255, 255, 0.75);
    margin-top: 0;
}

.footer-main {
    padding: 70px 0 40px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
}

.footer-logo {
    height: 50px;
}

.footer-brand h4 {
    color: var(--white);
    margin: 0;
    font-size: 20px;
}

.footer-about-text {
    line-height: 1.8;
    margin-bottom: 20px;
    font-size: 14px;
}

.footer-social a {
    display: inline-block;
    width: 38px;
    height: 38px;
    line-height: 38px;
    text-align: center;
    background: rgba(255, 255, 255, 0.08);
    color: var(--white);
    border-radius: 50%;
    margin-left: 6px;
    transition: var(--transition);
}

.footer-social a:hover {
    background: var(--accent);
    transform: translateY(-3px);
}

.footer-title {
    color: var(--white);
    margin-bottom: 22px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
    font-size: 18px;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.footer-links a:hover {
    color: var(--accent-2);
    padding-right: 5px;
}

.footer-links i {
    font-size: 12px;
    color: var(--accent);
}

.footer-contact {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-contact li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
    font-size: 14px;
}

.footer-contact i {
    color: var(--accent-2);
    margin-top: 5px;
    flex-shrink: 0;
}

.footer-contact a {
    color: rgba(255, 255, 255, 0.75);
}

.footer-contact a:hover {
    color: var(--accent-2);
}

.footer-bottom {
    padding: 20px 0;
    background: rgba(0, 0, 0, 0.3);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
}

.admin-link {
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
}

.admin-link:hover {
    color: var(--accent-2);
}

/* =================== FLOATING =================== */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 60px;
    height: 60px;
    line-height: 60px;
    background: #25d366;
    color: var(--white) !important;
    border-radius: 50%;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    transition: var(--transition);
    animation: pulse 2s infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    color: var(--white);
}

@keyframes pulse {
    0% { box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4); }
    50% { box-shadow: 0 8px 25px rgba(37, 211, 102, 0.7); }
    100% { box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4); }
}

.form-float-wrap {
    position: fixed;
    bottom: 105px;
    left: 30px;
    z-index: 1000;
}

.form-float {
    display: block;
    width: 60px;
    height: 60px;
    line-height: 60px;
    background: #f59e0b;
    color: var(--white) !important;
    border-radius: 50%;
    text-align: center;
    font-size: 26px;
    box-shadow: 0 8px 25px rgba(245, 158, 11, 0.4);
    transition: var(--transition);
    animation: pulse-form 2s infinite;
}

.form-float:hover {
    transform: scale(1.1);
    color: var(--white);
}

.form-float-tip {
    position: absolute;
    top: 50%;
    left: 75px;
    transform: translateY(-50%) scale(0.8);
    white-space: nowrap;
    background: #1f2a44;
    color: #fff;
    padding: 9px 16px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.form-float-tip::before {
    content: '';
    position: absolute;
    top: 50%;
    left: -7px;
    transform: translateY(-50%);
    border-top: 7px solid transparent;
    border-bottom: 7px solid transparent;
    border-right: 8px solid #1f2a44;
}

.form-float-tip.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) scale(1);
}

@media (max-width: 575px) {
    .form-float-tip {
        font-size: 12px;
        padding: 7px 12px;
    }
}

/* ===== Banners Slider ===== */
.banners-section {
    padding: 40px 0 10px;
}

.banners-carousel {
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(13, 27, 70, 0.15);
}

.banners-carousel .carousel-item {
    background: #0d1b46;
}

.banners-carousel.carousel-fade .carousel-item {
    transition: opacity 0.8s ease-in-out;
}

.banners-carousel.carousel-fade .carousel-item.active {
    opacity: 1;
}

.banner-slide {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 5;
    overflow: hidden;
}

.banner-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.banner-link {
    display: block;
    text-decoration: none;
}

.banner-caption {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    text-align: right;
    gap: 14px;
    padding: 0 6%;
    color: #fff;
    background: linear-gradient(90deg, rgba(13, 27, 70, 0.78) 0%, rgba(13, 27, 70, 0.45) 45%, rgba(13, 27, 70, 0) 80%);
}

.banner-title {
    font-size: 2.2rem;
    font-weight: 800;
    margin: 0;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
    max-width: 650px;
}

.banner-subtitle {
    font-size: 1.1rem;
    margin: 0;
    max-width: 560px;
    line-height: 1.8;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
}

.banner-btn {
    margin-top: 6px;
}

.banners-carousel .carousel-indicators {
    margin-bottom: 0.8rem;
}

.banners-carousel .carousel-indicators [data-bs-target] {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid #fff;
    background-color: rgba(255, 255, 255, 0.4);
}

.banners-carousel .carousel-indicators .active {
    background-color: #fff;
}

.banners-carousel .carousel-control-prev,
.banners-carousel .carousel-control-next {
    width: 6%;
    opacity: 0.85;
}

@media (max-width: 991px) {
    .banner-slide { aspect-ratio: 16 / 7; }
    .banner-title { font-size: 1.6rem; }
    .banner-subtitle { font-size: 1rem; }
}

@media (max-width: 575px) {
    .banners-section { padding: 25px 0 5px; }
    .banner-slide { aspect-ratio: 4 / 3; }
    .banner-caption {
        padding: 0 7%;
        gap: 10px;
        background: linear-gradient(90deg, rgba(13, 27, 70, 0.82) 0%, rgba(13, 27, 70, 0.55) 60%, rgba(13, 27, 70, 0.25) 100%);
    }
    .banner-title { font-size: 1.25rem; }
    .banner-subtitle { font-size: 0.85rem; line-height: 1.6; }
    .banner-btn { padding: 8px 16px; font-size: 0.85rem; }
}

@keyframes pulse-form {
    0% { box-shadow: 0 8px 25px rgba(245, 158, 11, 0.4); }
    50% { box-shadow: 0 8px 25px rgba(245, 158, 11, 0.7); }
    100% { box-shadow: 0 8px 25px rgba(245, 158, 11, 0.4); }
}

.scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-md);
}

.scroll-top.show {
    opacity: 1;
    visibility: visible;
}

.scroll-top:hover {
    background: var(--accent);
    transform: translateY(-3px);
}

/* =================== RESPONSIVE =================== */
@media (max-width: 991px) {
    .hero-title { font-size: 38px; }
    .hero-subtitle { font-size: 16px; }
    .section-title { font-size: 30px; }
    .navbar-collapse {
        background: var(--white);
        margin-top: 12px;
        padding: 15px;
        border-radius: var(--radius-sm);
        box-shadow: var(--shadow-sm);
    }
    .search-form {
        margin-top: 12px;
        margin-right: 0;
        width: 100%;
    }
    .search-form .form-control { width: 100%; flex: 1; }
    .main-navbar .nav-link.nav-login-link,
    .main-navbar .nav-link.nav-account-link,
    .main-navbar .nav-link.nav-install-link {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 100%;
        margin-right: 0;
        margin-top: 10px;
    }
    .main-navbar .navbar-nav .dropdown-menu {
        text-align: center;
        box-shadow: none;
        border: 1px solid var(--gray-200);
    }
}

@media (max-width: 767px) {
    .hero-section { padding: 60px 0 120px; }
    .hero-title { font-size: 30px; }
    .hero-stats { gap: 20px; }
    .stat-number { font-size: 28px; }
    .section-title { font-size: 24px; }
    .features-section { padding: 50px 0; margin-top: -60px; }
    .about-section, .services-section, .goals-section { padding: 60px 0; }
    .service-detail-content,
    .contact-form-wrap { padding: 25px; }
    .cta-box { padding: 35px 25px; text-align: center; }
    .page-header h1 { font-size: 30px; }
    .brand-tagline { display: none; }
    .brand-name { font-size: 15px; }
    .logo-img { height: 40px; }
}

/* =================== PWA INSTALL BANNER =================== */
.pwa-install-banner {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(140%);
    width: calc(100% - 32px);
    max-width: 440px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: 16px 18px;
    z-index: 1100;
    opacity: 0;
    transition: transform 0.35s ease, opacity 0.35s ease;
}

.pwa-install-banner.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.pwa-banner-inner {
    display: flex;
    align-items: center;
    gap: 14px;
}

.pwa-icon {
    flex: 0 0 auto;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.pwa-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pwa-icon i {
    color: var(--white);
    font-size: 24px;
}

.pwa-text {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    line-height: 1.4;
}

.pwa-text strong {
    color: var(--gray-900);
    font-size: 15px;
}

.pwa-text span {
    color: var(--gray-500);
    font-size: 12.5px;
}

.pwa-install-btn {
    flex: 0 0 auto;
    background: var(--gradient-primary);
    color: var(--white);
    border: none;
    border-radius: var(--radius-sm);
    padding: 10px 18px;
    font-family: inherit;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.pwa-install-btn:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
}

.pwa-close {
    position: absolute;
    top: 8px;
    left: 10px;
    width: 26px;
    height: 26px;
    border: none;
    background: var(--gray-100);
    color: var(--gray-500);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    transition: var(--transition);
}

.pwa-close:hover {
    background: var(--danger);
    color: var(--white);
}

.pwa-ios-steps {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed var(--gray-200);
    font-size: 13px;
    color: var(--gray-700);
}

.pwa-ios-steps p {
    margin: 0 0 6px;
    font-weight: 700;
    color: var(--gray-900);
}

.pwa-ios-steps ol {
    margin: 0;
    padding-right: 18px;
}

.pwa-ios-steps li {
    margin-bottom: 4px;
}

.pwa-ios-steps i {
    color: var(--secondary);
}

@media (max-width: 575px) {
    .pwa-text span { font-size: 11.5px; }
    .pwa-install-btn { padding: 9px 14px; font-size: 13px; }
    .pwa-icon { width: 46px; height: 46px; }
}

/* =================== WORKS / PORTFOLIO =================== */
.works-section {
    padding: 80px 0;
    background: var(--gray-100);
}

.works-filter {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-bottom: 40px;
}

.work-filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: var(--white);
    color: var(--gray-700);
    border: 1px solid var(--gray-200);
    border-radius: 50px;
    font-weight: 600;
    font-size: 14px;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.work-filter-btn:hover,
.work-filter-btn.active {
    background: var(--gradient-primary);
    color: var(--white);
    border-color: transparent;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.work-card .service-card-image {
    position: relative;
}

.work-category-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    background: rgba(255, 255, 255, 0.95);
    color: var(--primary);
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 700;
    z-index: 2;
    box-shadow: var(--shadow-sm);
}

.work-category-badge i {
    margin-left: 5px;
    color: var(--accent);
}

@media (max-width: 767px) {
    .works-section { padding: 60px 0; }
    .works-filter { gap: 8px; margin-bottom: 28px; }
    .work-filter-btn { padding: 8px 14px; font-size: 13px; }
}

/* =================== Auth (Login / Register / Account) =================== */
.auth-section {
    padding: 70px 0;
    background: var(--gray-100);
}

.auth-card {
    max-width: 460px;
    margin: 0 auto;
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 40px 35px;
    border: 1px solid var(--gray-200);
}

.auth-head {
    text-align: center;
    margin-bottom: 28px;
}

/* الشخصية المتحركة في صفحة الدخول */
.auth-buddy {
    width: 120px;
    height: 120px;
    margin: 0 auto 16px;
    filter: drop-shadow(0 8px 18px rgba(13, 27, 70, 0.25));
}

.auth-buddy svg {
    width: 100%;
    height: 100%;
    overflow: visible;
}

.auth-buddy .buddy-pupil {
    transition: cx 0.15s ease, cy 0.15s ease;
}

.auth-buddy .buddy-mouth {
    transition: d 0.25s ease;
}

/* العينان تطرفان تلقائيًا */
.auth-buddy .buddy-eyes {
    transform-origin: center 88px;
    animation: buddyBlink 4s infinite;
}

@keyframes buddyBlink {
    0%, 92%, 100% { transform: scaleY(1); }
    96% { transform: scaleY(0.1); }
}

/* اليدان مخفية بالأسفل افتراضيًا */
.auth-buddy .buddy-hand {
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* عند كتابة كلمة المرور: ترفع يديها وتغطي عينيها */
.auth-buddy.is-covering .buddy-hand-left {
    transform: translate(14px, -78px);
}
.auth-buddy.is-covering .buddy-hand-right {
    transform: translate(-14px, -78px);
}
.auth-buddy.is-covering .buddy-eyes {
    animation: none;
    opacity: 0;
}

/* الترحيب الأولي: تلويح اليد */
.auth-buddy.is-waving .buddy-hand-right {
    transform-origin: 140px 180px;
    animation: buddyWave 0.5s ease-in-out 0s 4;
}

@keyframes buddyWave {
    0%, 100% { transform: translateY(-44px) rotate(0deg); }
    50% { transform: translateY(-44px) rotate(-22deg); }
}

.auth-icon {
    width: 70px;
    height: 70px;
    line-height: 70px;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: var(--white);
    font-size: 30px;
    box-shadow: var(--shadow-md);
}

.auth-head h2 {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 6px;
}

.auth-head p {
    color: var(--gray-500);
    font-size: 14px;
    margin: 0;
}

.auth-form .form-label {
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 6px;
}

.auth-form .form-label i {
    color: var(--accent);
    margin-left: 4px;
}

.auth-form .form-control {
    border-radius: var(--radius-md);
    border: 1px solid var(--gray-200);
}

.auth-form .form-control:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 0.2rem rgba(0, 90, 158, 0.15);
}

.auth-foot {
    text-align: center;
    margin-top: 22px;
    font-size: 14px;
    color: var(--gray-500);
}

.auth-foot a {
    color: var(--accent);
    font-weight: 700;
}

.auth-foot a:hover {
    color: var(--primary);
}

.account-info-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.account-info-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 4px;
    border-bottom: 1px solid var(--gray-200);
}

.account-info-list li:last-child {
    border-bottom: none;
}

.account-info-list li span {
    color: var(--gray-500);
    font-size: 14px;
}

.account-info-list li span i {
    color: var(--accent);
    margin-left: 6px;
}

.account-info-list li strong {
    color: var(--primary);
}

@media (max-width: 575px) {
    .auth-card { padding: 30px 22px; }
}

/* نافذة طلب الخدمة (Login Prompt) */
.login-prompt-modal {
    border: none;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.login-prompt-modal .modal-title {
    font-weight: 800;
    color: var(--primary);
}

.login-prompt-modal .modal-title i {
    color: var(--accent);
    margin-left: 6px;
}

.login-prompt-modal .modal-body {
    padding: 10px 28px 32px;
}

.login-prompt-icon {
    font-size: 64px;
    line-height: 1;
    margin-bottom: 14px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.login-prompt-text {
    color: var(--gray-500);
    font-size: 15px;
    margin-bottom: 22px;
}

.btn-outline-primary-custom {
    background: transparent;
    color: var(--primary);
    padding: 12px 30px;
    border: 2px solid var(--primary);
    border-radius: 50px;
    font-weight: 700;
    transition: var(--transition);
}

.btn-outline-primary-custom:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-3px);
}

.btn-skip {
    background: transparent;
    color: var(--gray-500);
    border: none;
    font-weight: 600;
    text-decoration: none;
    padding: 10px;
    border-radius: 50px;
    transition: var(--transition);
}

.btn-skip:hover {
    color: var(--accent);
    background: var(--gray-100);
}

/* =================== Smart Chatbot =================== */
.chatbot-wrap {
    position: fixed;
    bottom: 30px;
    left: 30px;
    z-index: 1050;
}

.chatbot-toggle {
    position: relative;
    width: 62px;
    height: 62px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    background: var(--gradient-primary);
    color: #fff;
    font-size: 26px;
    box-shadow: 0 10px 28px rgba(13, 27, 70, 0.35);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chatbot-toggle:hover {
    transform: scale(1.08);
}

.chatbot-tip {
    position: absolute;
    bottom: 16px;
    left: 74px;
    white-space: nowrap;
    background: #0d1b46;
    color: #fff;
    padding: 10px 16px;
    border-radius: 14px;
    font-size: 13.5px;
    font-weight: 700;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.28);
    opacity: 0;
    visibility: hidden;
    transform: scale(0.8);
    transform-origin: left center;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.chatbot-tip::before {
    content: '';
    position: absolute;
    top: 50%;
    left: -7px;
    transform: translateY(-50%);
    border-top: 7px solid transparent;
    border-bottom: 7px solid transparent;
    border-right: 8px solid #0d1b46;
}

.chatbot-tip.show {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

.chatbot-toggle .chatbot-toggle-icon {
    animation: botFloat 2.2s ease-in-out infinite;
}

.chatbot-toggle .chatbot-close-icon {
    display: none;
}

.chatbot-wrap.open .chatbot-toggle .chatbot-toggle-icon { display: none; }
.chatbot-wrap.open .chatbot-toggle .chatbot-close-icon { display: inline-block; }

@keyframes botFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

/* حركة دخول الروبوت: يأتي من بعيد ويدور حول الموقع ثم يستقر */
.chatbot-wrap.bot-entrance {
    animation: botFlyIn 2.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.chatbot-wrap.bot-entrance .chatbot-toggle {
    animation: botSpin 2.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes botFlyIn {
    0%   { opacity: 0; transform: translate(62vw, -86vh) scale(0.1); }
    8%   { opacity: 1; }
    22%  { transform: translate(72vw, -22vh) scale(0.4); }
    38%  { transform: translate(26vw, -80vh) scale(0.6); }
    55%  { transform: translate(-3vw, -28vh) scale(0.8); }
    70%  { transform: translate(46vw, -58vh) scale(0.95); }
    85%  { transform: translate(7vw, -12vh) scale(1.15); }
    93%  { transform: translate(-2vw, 4px) scale(0.95); }
    100% { opacity: 1; transform: translate(0, 0) scale(1); }
}

@keyframes botSpin {
    0%   { transform: rotate(-540deg); }
    85%  { transform: rotate(20deg); }
    100% { transform: rotate(0deg); }
}

@media (prefers-reduced-motion: reduce) {
    .chatbot-wrap.bot-entrance,
    .chatbot-wrap.bot-entrance .chatbot-toggle { animation: none; }
}

/* وميض الكلمة عند قفز الروبوت عليها */
.bot-word-hit {
    animation: botWordHit 0.65s ease;
}

@keyframes botWordHit {
    0%   { transform: scale(1); }
    35%  { transform: scale(1.12); filter: drop-shadow(0 4px 10px rgba(0, 184, 217, 0.6)); color: var(--accent); }
    100% { transform: scale(1); }
}

.chatbot-ping {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 14px;
    height: 14px;
    background: var(--success);
    border: 2px solid #fff;
    border-radius: 50%;
    animation: botPing 1.8s ease-in-out infinite;
}

.chatbot-wrap.open .chatbot-ping { display: none; }

@keyframes botPing {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6); }
    70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.chatbot-panel {
    position: absolute;
    bottom: 78px;
    left: 0;
    width: 350px;
    max-width: calc(100vw - 40px);
    height: 480px;
    max-height: calc(100vh - 140px);
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 18px 50px rgba(13, 27, 70, 0.3);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateY(20px) scale(0.96);
    opacity: 0;
    transform-origin: bottom left;
    transition: transform 0.25s ease, opacity 0.25s ease;
}

.chatbot-wrap.open .chatbot-panel {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.chatbot-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 18px;
    background: var(--gradient-primary);
    color: #fff;
}

.chatbot-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.chatbot-head-info {
    display: flex;
    flex-direction: column;
    line-height: 1.4;
}

.chatbot-head-info strong { font-size: 15px; }

.chatbot-status {
    font-size: 12px;
    opacity: 0.9;
    display: flex;
    align-items: center;
    gap: 5px;
}

.chatbot-status .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    display: inline-block;
}

.chatbot-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    background: var(--gray-100);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-msg {
    display: flex;
    max-width: 85%;
}

.chat-msg.bot { align-self: flex-start; }
.chat-msg.user { align-self: flex-end; }

.chat-bubble {
    padding: 10px 14px;
    border-radius: 16px;
    font-size: 14px;
    line-height: 1.7;
    box-shadow: var(--shadow-sm);
    white-space: pre-line;
    word-break: break-word;
}

.chat-msg.bot .chat-bubble {
    background: #fff;
    color: var(--gray-700);
    border-bottom-right-radius: 4px;
}

.chat-msg.user .chat-bubble {
    background: var(--secondary);
    color: #fff;
    border-bottom-left-radius: 4px;
}

.chat-links {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 10px;
}

.chat-link-btn {
    display: block;
    background: var(--secondary);
    color: #fff !important;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    transition: var(--transition);
}

.chat-link-btn:hover {
    background: var(--primary);
    transform: translateY(-1px);
}

/* اقتراحات سريعة تفاعلية داخل المحادثة */
.chat-suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 4px 0 8px;
    padding-right: 6px;
    animation: suggIn 0.25s ease;
}

@keyframes suggIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.chat-suggestion {
    border: 1.5px solid var(--accent);
    background: rgba(0, 184, 217, 0.08);
    color: var(--secondary);
    border-radius: 50px;
    padding: 6px 13px;
    font-size: 12.5px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.chat-suggestion:hover {
    background: var(--secondary);
    color: #fff;
    border-color: var(--secondary);
    transform: translateY(-1px);
}

.chat-typing {
    display: flex;
    gap: 4px;
    align-items: center;
}

.chat-typing span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--gray-300);
    animation: botType 1s infinite;
}

.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes botType {
    0%, 60%, 100% { transform: translateY(0); opacity: 0.5; }
    30% { transform: translateY(-5px); opacity: 1; }
}

.chatbot-quick {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 10px 12px 0;
    background: #fff;
}

.chatbot-quick .chip {
    border: 1px solid var(--gray-200);
    background: var(--gray-100);
    color: var(--primary);
    border-radius: 50px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.chatbot-quick .chip:hover {
    background: var(--secondary);
    color: #fff;
    border-color: var(--secondary);
}

.chatbot-input {
    display: flex;
    gap: 8px;
    padding: 12px;
    background: #fff;
    border-top: 1px solid var(--gray-200);
}

.chatbot-input input {
    flex: 1;
    border: 1px solid var(--gray-200);
    border-radius: 50px;
    padding: 10px 16px;
    font-size: 14px;
    outline: none;
    background: var(--gray-100);
    font-family: inherit;
}

.chatbot-input input:focus {
    border-color: var(--accent);
    background: #fff;
}

.chatbot-input button {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: #fff;
    cursor: pointer;
    flex-shrink: 0;
    transition: var(--transition);
}

.chatbot-input button:hover { filter: brightness(1.1); }

@media (max-width: 575px) {
    .chatbot-wrap { bottom: 20px; left: 20px; }
    .chatbot-panel { height: 70vh; }
}

/* =====================================================
   تحسينات التجاوب الشاملة (هواتف / أجهزة لوحية / حواسيب)
   ===================================================== */

/* منع التمرير الأفقي وضبط الوسائط */
html, body { max-width: 100%; overflow-x: hidden; }

img, video, svg, iframe { max-width: 100%; height: auto; }

.table-responsive { -webkit-overflow-scrolling: touch; }

/* أجهزة لوحية / آيباد (768 - 1024) */
@media (min-width: 768px) and (max-width: 1024px) {
    .hero-title { font-size: 44px; }
    .hero-subtitle { font-size: 17px; }
    .section-title { font-size: 32px; }
    .hero-section { padding: 80px 0 140px; }
    .service-card-body { padding: 18px; }
    .request-form-wrap { padding: 32px; }
    .container { padding-left: 24px; padding-right: 24px; }
}

/* هواتف وأجهزة لوحية صغيرة (أقل من 768) */
@media (max-width: 767.98px) {
    /* شبكات تتحول لعمود واحد بسلاسة */
    .hero-stats { flex-wrap: wrap; justify-content: center; }
    .hero-buttons { flex-wrap: wrap; }
    .hero-buttons .btn { flex: 1 1 auto; }

    /* الفورما واستمارة الطلب */
    .request-form-wrap { padding: 22px; }
    .color-picker { gap: 6px; }

    /* الأزرار الكبيرة تملأ العرض على الجوال */
    .btn-primary-custom.btn-lg,
    .btn-outline-primary-custom.btn-lg { width: 100%; justify-content: center; }

    /* الجداول في لوحة الإدارة قابلة للتمرير */
    table { font-size: 14px; }

    /* تقليل المسافات العامة */
    section { background-attachment: scroll !important; }
}

/* هواتف متوسطة (أقل من 576) */
@media (max-width: 575.98px) {
    .container { padding-left: 16px; padding-right: 16px; }
    .hero-title { font-size: 26px; }
    .hero-subtitle { font-size: 14px; }
    .section-title { font-size: 22px; }
    .page-header { padding: 40px 0; }
    .page-header h1 { font-size: 26px; }

    .service-card-body { padding: 16px; }
    .service-title { font-size: 17px; }

    .stat-number { font-size: 24px; }
    .hero-stats { gap: 14px; }

    .request-form-head { gap: 10px; }
    .request-form-head h3 { font-size: 18px; }

    /* الروبوت ولوحته */
    .chatbot-toggle { width: 56px; height: 56px; font-size: 22px; }
    .chatbot-panel {
        width: calc(100vw - 24px);
        left: 0;
        height: 68vh;
    }
    .pwa-install-chip { padding: 7px 12px; font-size: 12.5px; }
}

/* هواتف صغيرة جدًا (أقل من 400) */
@media (max-width: 400px) {
    .hero-title { font-size: 23px; }
    .section-title { font-size: 20px; }
    .pwa-install-chip span { display: none; } /* أيقونة فقط لتوفير المساحة */
    .pwa-install-chip { padding: 8px 11px; }
    .brand-name { font-size: 14px; }
    .logo-img { height: 36px; }
    .color-swatch { font-size: 12px; padding: 4px 9px 4px 7px; }
}

/* شاشات كبيرة جدًا: حصر العرض لراحة القراءة */
@media (min-width: 1400px) {
    .container { max-width: 1280px; }
}

/* دعم اللمس: تكبير مناطق النقر */
@media (hover: none) and (pointer: coarse) {
    .nav-link, .btn, .chat-suggestion, .color-swatch, .chip {
        min-height: 40px;
    }
}
