/* ============================================
   ScienceMed - Home Page Styles
   Direction: RTL | Colors: Blue & White
   Font: Cairo (Google Fonts)
   ============================================ */

/* ---------- Google Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700;800;900&display=swap');

/* ---------- CSS Variables ---------- */
:root {
    /* Primary Blues */
    --primary-900: #023e8a;
    --primary-800: #0353a4;
    --primary-700: #0466c8;
    --primary-600: #0077b6;
    --primary-500: #0096c7;
    --primary-400: #00b4d8;
    --primary-300: #48cae4;
    --primary-200: #90e0ef;
    --primary-100: #caf0f8;

    /* Neutrals */
    --white: #ffffff;
    --gray-50: #f8f9fa;
    --gray-100: #e9ecef;
    --gray-200: #dee2e6;
    --gray-300: #ced4da;
    --gray-700: #495057;
    --gray-800: #343a40;
    --gray-900: #212529;

    /* Background & Text */
    --bg-primary: #bfd4e6;
    --bg-main: #d9e8f5;
    --bg-card: #d9e8f5;
    --bg-footer: #96b5d2;
    --bg-secondary: #d9e8f5;
    --bg-header: var(--primary-600);
    --bg-navbar: var(--primary-800);
    --text-primary: var(--gray-900);
    --text-secondary: var(--gray-700);
    --text-light: var(--white);

    /* Shadows & Transitions */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.12);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.2);
    --transition: all 0.3s ease;
    --transition-slow: all 0.6s ease;
}

/* ---------- Dark Mode Variables ---------- */
[data-theme="dark"] {
    --bg-primary: #0a1628;
    --bg-main: #0f1f3a;
    --bg-card: #112240;
    --bg-footer: #0c182c;
    --bg-secondary: #0f1f3a;
    --bg-header: #0d1b33;
    --bg-navbar: #081425;
    
    
    
    
    
    
    --text-primary: #e0e6ed;
    --text-secondary: #a0aec0;
    --text-light: #ffffff;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.6);
}

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Cairo', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ---------- Header ---------- */
.header {
    background: linear-gradient(135deg, var(--primary-700) 0%, var(--primary-600) 50%, var(--primary-500) 100%);
    padding: 10px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-md);
    position: relative;
    z-index: 100;
}

[data-theme="dark"] .header {
    background: linear-gradient(135deg, #0d1b33 0%, #122240 50%, #162a4d 100%);
}

.header__brand {
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition);
}

.header__brand:hover {
    opacity: 0.9;
}

.header__logo-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.header__brand:hover .header__logo-wrapper {
    transform: scale(1.05);
}

.header__logo {
    height: 64px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.18));
    transition: var(--transition);
}

.header__info {
    display: flex;
    flex-direction: column;
}

.header__title {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--white);
    letter-spacing: 1.5px;
    line-height: 1.2;
    text-transform: uppercase;
}

.header__subtitle {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 400;
    letter-spacing: 0.5px;
}

.header__controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* ---------- Toggle Buttons ---------- */
.toggle-btn {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: var(--white);
    padding: 8px 16px;
    border-radius: 25px;
    cursor: pointer;
    font-family: 'Cairo', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.toggle-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-1px);
}

.toggle-btn i {
    font-size: 1rem;
}

.toggle-btn--active {
    background: rgba(255, 255, 255, 0.9);
    color: var(--primary-700);
}

/* ---------- Navigation Bar ---------- */
.navbar {
    background: var(--bg-navbar);
    padding: 0 40px;
    box-shadow: var(--shadow-sm);
    position: relative;
    z-index: 99;
}

[data-theme="dark"] .navbar {
    background: #081425;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.navbar__list {
    display: flex;
    align-items: center;
    gap: 0;
}

.navbar__item {}

.navbar__link {
    display: block;
    padding: 14px 28px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    font-weight: 600;
    position: relative;
    transition: var(--transition);
}

.navbar__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 3px;
    background: var(--primary-300);
    transition: var(--transition);
    border-radius: 3px 3px 0 0;
}

.navbar__link:hover,
.navbar__link--active {
    color: var(--white);
    background: rgba(255, 255, 255, 0.08);
}

.navbar__link:hover::after,
.navbar__link--active::after {
    width: 100%;
}

/* Hamburger Menu (Mobile) */
.navbar__toggle {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 14px 0;
}

/* ---------- Hero Slider ---------- */
.slider-wrapper {
    width: 100%;
    padding: 10px 0 40px 0;
    background: transparent;
}
.slider {
    position: relative;
    width: 95%;
    max-width: 1800px;
    height: calc(90vh - 100px);
    min-height: 400px;
    max-height: 900px;
    margin: 0 auto;
    overflow: hidden;
    background: var(--primary-900);
    border-radius: 20px;
    border: none;
    box-shadow: none;
}

.slider__slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider__slide--active {
    opacity: 1;
}

.slider__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

/* Dark Mode Adjustments for Slider Images */
[data-theme="dark"] .slider__image {
    filter: brightness(0.85) contrast(1.1);
}

[data-theme="dark"] .slider__slide::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(10, 22, 40, 0.35); /* Subtle dark navy overlay */
    pointer-events: none;
}

.slider__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(2, 62, 138, 0.3) 0%, rgba(2, 62, 138, 0.5) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
}

/* ---------- Enhanced Hero Slide 1 (Vision & Brand) ---------- */
.hero-vision-overlay {
    background: radial-gradient(circle at center, rgba(3, 17, 34, 0.45) 0%, rgba(2, 10, 22, 0.82) 100%) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    padding: 20px 24px !important;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 18px;
    border-radius: 50px;
    border: 1.5px solid #00d2ff;
    background: rgba(3, 22, 46, 0.75);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 0 16px rgba(0, 210, 255, 0.35), inset 0 0 10px rgba(0, 210, 255, 0.15);
    margin-bottom: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 22px rgba(0, 210, 255, 0.55), inset 0 0 12px rgba(0, 210, 255, 0.25);
}

.hero-badge__icon {
    color: #00e5ff;
    font-size: 0.95rem;
    filter: drop-shadow(0 0 4px #00e5ff);
}

.hero-badge__text {
    color: #00f0ff;
    font-family: 'Alexandria', 'Tajawal', 'Cairo', sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.5px;
    text-shadow: 0 0 8px rgba(0, 240, 255, 0.5);
}

.hero-sciencemed-wrapper {
    position: relative;
    display: inline-block;
    margin: 2px 0 6px 0;
}

.hero-sciencemed-wrapper::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 120%;
    background: radial-gradient(ellipse at center, rgba(0, 210, 255, 0.45) 0%, rgba(0, 150, 255, 0.2) 45%, transparent 72%);
    filter: blur(20px);
    z-index: 0;
    pointer-events: none;
}

.hero-sciencemed-title {
    position: relative;
    z-index: 1;
    font-family: 'Poppins', 'Montserrat', Arial, sans-serif;
    font-weight: 900;
    font-size: clamp(2.8rem, 6.8vw, 5.5rem);
    letter-spacing: 3px;
    line-height: 1.05;
    margin: 0;
    color: #ffffff;
    text-shadow: 
        0 0 12px #00f0ff,
        0 0 25px rgba(0, 240, 255, 0.8),
        0 0 50px rgba(0, 180, 255, 0.6),
        0 0 80px rgba(0, 140, 255, 0.4);
    text-transform: uppercase;
}

.hero-subtitle-line {
    font-family: 'Alexandria', 'Tajawal', 'Cairo', sans-serif;
    font-weight: 800;
    font-size: clamp(1.15rem, 2.9vw, 2.1rem);
    color: #ffffff;
    margin: 6px 0 12px 0;
    white-space: nowrap;
    text-shadow: 0 3px 12px rgba(0, 0, 0, 0.9), 0 0 10px rgba(0, 210, 255, 0.25);
    letter-spacing: 0.3px;
}

.hero-quote-frame {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    max-width: 95%;
    background: rgba(5, 18, 38, 0.75);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1.5px solid rgba(0, 210, 255, 0.4);
    border-radius: 14px;
    padding: 10px 28px;
    margin: 8px auto 0 auto;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.55), inset 0 0 20px rgba(0, 210, 255, 0.1);
    box-sizing: border-box;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.hero-quote-frame:hover {
    border-color: rgba(0, 210, 255, 0.6);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55), inset 0 0 25px rgba(0, 210, 255, 0.15);
}

.hero-quote-text {
    font-family: 'Tajawal', 'Cairo', sans-serif;
    font-weight: 600;
    font-size: clamp(0.85rem, 1.4vw, 1.08rem);
    color: #e2f1ff;
    line-height: 1.4;
    margin: 0;
    text-align: center;
    white-space: normal;
    word-break: normal;
    overflow-wrap: break-word;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.8);
}

.hero-iso-subtitle-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    margin: 4px 0 10px 0;
}

.hero-iso-subtitle {
    font-family: 'Alexandria', 'Tajawal', 'Cairo', sans-serif;
    font-weight: 800;
    font-size: clamp(1.1rem, 2.5vw, 1.85rem);
    color: #ffffff;
    margin: 0;
    line-height: 1.25;
    text-shadow: 0 3px 12px rgba(0, 0, 0, 0.9), 0 0 10px rgba(0, 210, 255, 0.3);
}

.hero-iso-subtext {
    font-family: 'Alexandria', 'Tajawal', 'Cairo', sans-serif;
    font-weight: 800;
    font-size: clamp(0.95rem, 2.1vw, 1.55rem);
    color: #ffffff;
    margin: 0;
    line-height: 1.25;
    letter-spacing: 0.8px;
    text-shadow: 0 3px 12px rgba(0, 0, 0, 0.9), 0 0 10px rgba(0, 210, 255, 0.3);
}

.slider__number {
    font-size: 5rem;
    font-weight: 900;
    color: var(--white);
    text-shadow: 2px 4px 12px rgba(0, 0, 0, 0.3);
    line-height: 1;
}

.slider__text {
    font-size: 1.5rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
    margin-top: 10px;
    text-shadow: 1px 2px 6px rgba(0, 0, 0, 0.3);
}

.slider__text-en {
    font-size: 1.2rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 5px;
}

/* Slider Dots */
.slider__dots {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.slider__dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.6);
    cursor: pointer;
    transition: var(--transition);
}

.slider__dot--active {
    background: var(--white);
    transform: scale(1.2);
}

/* ---------- Main Content Section ---------- */
.main-content {
    padding: 60px 40px;
    background: var(--bg-primary);
    transition: var(--transition);
}

.section-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-700);
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

[data-theme="dark"] .section-title {
    color: var(--primary-300);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -5px;
    right: 0;
    width: 100%; /* Matches the exact width of the word */
    height: 3px;
    background: linear-gradient(to left, var(--primary-600), var(--primary-300));
    border-radius: 3px;
}

.section-text {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.9;
    max-width: 800px;
}

/* Welcome Section */
.welcome {
    text-align: center;
    padding: 80px 40px;
    background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
}

.welcome__title {
    font-size: 2.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--primary-700), var(--primary-500));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
}

[data-theme="dark"] .welcome__title {
    background: linear-gradient(135deg, var(--primary-300), var(--primary-200));
    -webkit-background-clip: text;
    background-clip: text;
}

.welcome__text {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 750px;
    margin: 0 auto;
    line-height: 2;
}

/* Features Cards */
.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    padding: 60px 40px;
    background: var(--bg-secondary);
}

.feature-card {
    background: var(--bg-primary);
    border-radius: 16px;
    padding: 35px 25px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid rgba(0, 119, 182, 0.1);
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-400);
}

.feature-card__icon {
    font-size: 2.8rem;
    color: var(--primary-600);
    margin-bottom: 18px;
}

[data-theme="dark"] .feature-card__icon {
    color: var(--primary-300);
}

.feature-card__title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.feature-card__text {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ---------- Footer ---------- */
.footer {
    background: linear-gradient(135deg, var(--primary-900) 0%, var(--primary-800) 100%);
    color: var(--white);
    padding: 40px;
    text-align: center;
}

[data-theme="dark"] .footer {
    background: linear-gradient(135deg, #060e1a 0%, #0a1628 100%);
}

.footer__text {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

.footer__text a {
    color: var(--primary-300);
    font-weight: 600;
}

.footer__text a:hover {
    color: var(--white);
}

/* ---------- Social Media Floating Buttons ---------- */
.social-float {
    position: fixed;
    /* Position handled by dir attribute */
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 1000;
}

.social-float__link {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.2rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    position: relative;
}

.social-float__link:hover {
    transform: scale(1.15);
    box-shadow: var(--shadow-lg);
}

/* Social specific colors */
.social-float__link--facebook {
    background: linear-gradient(135deg, #1877f2, #0d65d9);
}

.social-float__link--whatsapp {
    background: linear-gradient(135deg, #25d366, #128c7e);
}
.social-float__link--telegram {
    background: linear-gradient(135deg, #0088cc, #005580);
}


.social-float__link--youtube {
    background: linear-gradient(135deg, #ff0000, #cc0000);
}

.social-float__link--tiktok {
    background: linear-gradient(135deg, #000000, #333333);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Social tooltip */
.social-float__link::before {
    content: attr(data-tooltip);
    position: absolute;
    /* Position handled by dir attribute */
    top: 50%;
    transform: translateY(-50%);
    background: var(--gray-900);
    color: var(--white);
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.social-float__link:hover::before {
    opacity: 1;
    visibility: visible;
}

/* ---------- Animations ---------- */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.8s ease forwards;
}

.animate-slideIn {
    animation: slideInRight 0.8s ease forwards;
}

/* ---------- Responsive Design ---------- */

/* Tablet */
@media (max-width: 992px) {
    .header {
        padding: 12px 24px;
    }

    .header__title {
        font-size: 1.25rem;
    }

    .navbar {
        padding: 0 24px;
    }

    .navbar__link {
        padding: 12px 18px;
        font-size: 0.88rem;
    }

    .slider__number {
        font-size: 4rem;
    }

    .slider__text {
        font-size: 1.2rem;
    }

    .welcome__title {
        font-size: 2rem;
    }

    .features {
        grid-template-columns: repeat(2, 1fr);
        padding: 40px 24px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .header {
        padding: 10px 16px;
        flex-wrap: wrap;
    }

    .header__logo { height: 48px; width: auto; }

    .header__title {
        font-size: 1.1rem;
    }

    .header__subtitle {
        font-size: 0.65rem;
    }

    .header__controls {
        gap: 8px;
    }

    .toggle-btn {
        padding: 6px 12px;
        font-size: 0.78rem;
    }

    /* Mobile Nav */
    .navbar {
        padding: 0 16px;
    }

    .navbar__toggle {
        display: block;
    }

    .navbar__list {
        display: none;
        flex-direction: column;
        width: 100%;
    }

    .navbar__list--open {
        display: flex;
    }

    .navbar__link {
        padding: 12px 16px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .navbar__link::after {
        display: none;
    }

    /* Slider */
    .slider__number {
        font-size: 3rem;
    }

    .slider__text {
        font-size: 1rem;
    }

    .slider__text-en {
        font-size: 0.85rem;
    }

    /* Welcome */
    .welcome {
        padding: 50px 16px;
    }

    .welcome__title {
        font-size: 1.6rem;
    }

    .welcome__text {
        font-size: 1rem;
    }

    /* Features */
    .features {
        grid-template-columns: 1fr;
        padding: 30px 16px;
        gap: 20px;
    }

    /* Social Float */
    .social-float {
        /* Position handled by dir attribute */
        gap: 8px;
    }

    .social-float__link {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .social-float__link::before {
        display: none;
    }

    /* Footer */
    .footer {
        padding: 30px 16px;
    }

    .main-content {
        padding: 40px 16px;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .header__brand {
        gap: 10px;
    }

    .header__logo { height: 40px; width: auto; }

    .header__title {
        font-size: 0.95rem;
    }

    .header__controls {
        width: 100%;
        justify-content: center;
        margin-top: 8px;
    }

    .slider__number {
        font-size: 2.5rem;
    }

    .slider__text {
        font-size: 0.9rem;
    }

    .welcome__title {
        font-size: 1.4rem;
    }
}

/* ---------- LTR Mode (English) ---------- */
[dir="ltr"] {
    text-align: left;
}

[dir="ltr"] .navbar__link::after {
    right: auto;
    left: 0;
}

[dir="ltr"] .section-title::after {
    right: auto;
    left: 0;
}

/* ========== Products Carousel ========== */
.products-carousel-section {
    position: relative;
    overflow: hidden;
    padding: 70px 0;
    background: linear-gradient(
        180deg,
        var(--bg-secondary) 0%,
        var(--bg-primary) 18%,
        var(--bg-primary) 82%,
        var(--bg-secondary) 100%
    );
    background: linear-gradient(
        180deg,
        var(--bg-secondary) 0%,
        color-mix(in srgb, var(--bg-secondary) 85%, var(--bg-primary)) 4%,
        color-mix(in srgb, var(--bg-secondary) 60%, var(--bg-primary)) 8%,
        color-mix(in srgb, var(--bg-secondary) 30%, var(--bg-primary)) 14%,
        var(--bg-primary) 22%,
        var(--bg-primary) 78%,
        color-mix(in srgb, var(--bg-secondary) 30%, var(--bg-primary)) 86%,
        color-mix(in srgb, var(--bg-secondary) 60%, var(--bg-primary)) 92%,
        color-mix(in srgb, var(--bg-secondary) 85%, var(--bg-primary)) 96%,
        var(--bg-secondary) 100%
    );
}

.carousel-container {
    display: flex;
    align-items: center;
}

.carousel-btn {
    background: var(--primary-600);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: background 0.3s, transform 0.2s;
    flex-shrink: 0;
}

.carousel-btn:hover {
    background: var(--primary-700);
    transform: scale(1.1);
}

.carousel-track-container {
    flex: 1 1 0%;
    min-width: 0;
    width: 100%;
    margin: 0 12px;
    overflow: hidden;
}

.carousel-track {
    --cards-per-view: 4;
    --carousel-gap: 20px;
    display: flex;
    align-items: stretch;
    gap: var(--carousel-gap);
    list-style: none;
    padding: 15px 0 22px 0;
    margin: 0;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.carousel-track::-webkit-scrollbar {
    display: none;
}

.carousel-track > li {
    flex: 0 0 calc((100% - (var(--cards-per-view) - 1) * var(--carousel-gap)) / var(--cards-per-view));
    max-width: calc((100% - (var(--cards-per-view) - 1) * var(--carousel-gap)) / var(--cards-per-view));
    box-sizing: border-box;
    padding: 0 6px;
    display: flex;
    justify-content: center;
    scroll-snap-align: start;
}

@media (max-width: 1099px) {
    .carousel-track {
        --cards-per-view: 3;
        --carousel-gap: 18px;
    }
}

@media (max-width: 819px) {
    .carousel-track {
        --cards-per-view: 2;
        --carousel-gap: 14px;
    }
}

@media (max-width: 539px) {
    .carousel-track {
        --cards-per-view: 1;
        --carousel-gap: 14px;
    }
}

.carousel-card {
    width: 100%;
    min-width: 0;
    max-width: 280px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    background: var(--bg-card);
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    text-decoration: none;
    border: 1px solid rgba(0,0,0,0.05);
}

[data-theme="dark"] .carousel-card {
    border: 1px solid rgba(255,255,255,0.05);
}

.carousel-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.carousel-card__img-container {
    height: 200px;
    flex-shrink: 0;
    background-color: transparent;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    border-bottom: none;
    padding: 20px;
    background-origin: content-box;
    transition: transform 0.3s;

    filter: drop-shadow(0 10px 15px rgba(0, 0, 0, 0.1));
}

.carousel-card__content {
    padding: 12px 10px;
    background: transparent;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
    text-align: center;
    flex: 1;
    min-height: 80px;
    box-sizing: border-box;
    width: 100%;
}

.carousel-card__name-ar {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.35;
    width: 100%;
    display: block;
}

.carousel-card__name-en {
    font-size: 1.05rem;
    font-weight: 600;
    font-family: Arial, sans-serif;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.35;
    width: 100%;
    display: block;
    text-transform: uppercase;
}

/* Responsive carousel card sizing handled via --cards-per-view */

/* Scroll Animations */
.fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.fade-up-active {
    opacity: 1;
    transform: translateY(0);
}
/* ========== Navbar Search ========== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar__search-container {
    position: relative;
    display: flex;
    align-items: center;
}

.navbar__search-input {
    padding: 8px 35px 8px 15px;
    border-radius: 20px;
    border: 1px solid var(--primary-300);
    outline: none;
    background: var(--bg-card);
    color: var(--text-color);
    font-size: 0.9rem;
    width: 250px;
    transition: all 0.3s ease;
}

.navbar__search-input:focus {
    border-color: var(--primary-600);
    box-shadow: 0 0 5px rgba(0, 119, 182, 0.3);
}

.navbar__search-icon {
    position: absolute;
    right: 12px;
    color: var(--primary-500);
    pointer-events: none;
}

[dir="rtl"] .navbar__search-input {
    padding: 8px 15px 8px 35px;
}

[dir="rtl"] .navbar__search-icon {
    right: auto;
    left: 12px;
}

.navbar__search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-radius: 8px;
    box-shadow: var(--shadow-md);
    margin-top: 10px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 100;
    display: none;
    border: 1px solid rgba(0,0,0,0.05);
}

[data-theme="dark"] .navbar__search-results {
    border: 1px solid rgba(255,255,255,0.05);
}

.navbar__search-results.active {
    display: block;
}

.search-result-item {
    padding: 10px 15px;
    cursor: pointer;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    display: flex;
    align-items: center;
    gap: 10px;
}

[data-theme="dark"] .search-result-item {
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: var(--bg-main);
}

.search-result-img {
    width: 30px;
    height: 30px;
    object-fit: contain;
    border-radius: 4px;
}

.search-result-name {
    font-size: 0.9rem;
    color: var(--text-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-no-results {
    padding: 15px;
    text-align: center;
    color: var(--text-color);
    font-size: 0.9rem;
    opacity: 0.7;
}

@media (max-width: 768px) {
    .navbar__search-input {
        width: 150px;
    }
}

/* ---------- Social Media Float Directions ---------- */



[dir="rtl"] .social-float__link::before {
    left: calc(100% + 12px);
    right: auto;
}
[dir="ltr"] .social-float__link::before {
    right: calc(100% + 12px);
    left: auto;
}

@media (max-width: 768px) {
    
    
}







@media (max-width: 768px) {
    
    
}


/* Human Health Button */
.human-health-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    background: linear-gradient(135deg, var(--primary-600), var(--primary-800)) !important;
}
/* ========== Footer Modern Styles ========== */
.footer-link {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
    display: inline-block;
}
.footer-link:hover {
    color: var(--primary-500);
    transform: translateX(-5px); /* Slide left in RTL */
}
html[dir="ltr"] .footer-link:hover {
    transform: translateX(5px); /* Slide right in LTR */
}

.footer-social:hover {
    background: var(--primary-500) !important;
    color: var(--white) !important;
    transform: translateY(-3px);
    box-shadow: var(--shadow-sm);
}

[data-theme="dark"] .footer {
    border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
}
[data-theme="dark"] .footer__bottom {
    background: transparent !important;
    border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
}

.footer-email:hover { color: var(--primary-500) !important; text-decoration: underline !important; }

.footer-human-btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    background: linear-gradient(135deg, var(--primary-600), var(--primary-800)) !important;
}

[data-theme="dark"] .slider { border: none; box-shadow: none; }

/* Lightning bolt */
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ffcc00;
    color: #333;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    font-size: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
}
/* Telegram Magic Glow */
@keyframes magic-pulse {
    0% { box-shadow: 0 0 0 0 rgba(0, 136, 204, 0.8), 0 0 15px rgba(0, 136, 204, 0.6); }
    50% { box-shadow: 0 0 0 15px rgba(0, 136, 204, 0), 0 0 25px rgba(0, 136, 204, 1); }
    100% { box-shadow: 0 0 0 0 rgba(0, 136, 204, 0), 0 0 15px rgba(0, 136, 204, 0.6); }
}
.telegram-magic {
    animation: magic-pulse 2s infinite ease-in-out !important;
    position: relative;
    z-index: 10;
}

/* Telegram Magic Circle & Fairy Dust */
.tg-dust-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 60px;
    height: 60px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    animation: tg-spin-dust 4s linear infinite;
}
.tg-dust-ring::before,
.tg-dust-ring::after {
    content: '';
    position: absolute;
    width: 2px;
    height: 2px;
    border-radius: 50%;
}
.tg-dust-ring::before {
    top: 5px; left: 50%;
    box-shadow: 
        10px -5px 3px #ff0000, 
        20px 5px 3px #ff7f00, 
        15px 20px 3px #ffff00, 
        -5px 20px 3px #00ff00, 
        -20px 10px 3px #0000ff, 
        -15px -10px 3px #4b0082, 
        -5px -20px 3px #9400d3;
    animation: tg-twinkle-dust 1s infinite alternate;
}
.tg-dust-ring::after {
    bottom: 5px; left: 50%;
    box-shadow: 
        15px 15px 2px #ffcc00, 
        -15px 15px 3px #00ffff, 
        -15px -15px 3px #ff00ff, 
        15px -15px 2px #00ff00,
        25px 0px 3px #ff0000,
        -25px 0px 3px #0000ff;
    animation: tg-twinkle-dust 1.5s infinite alternate-reverse;
}

.tg-stars-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 75px;
    height: 75px;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: -1;
    animation: tg-spin-stars 10s linear infinite reverse;
}
.tg-stars-circle i {
    position: absolute;
    color: #ffcc00;
    font-size: 9px;
    text-shadow: 0 0 5px rgba(255,255,255,0.8);
    animation: tg-star-blink 1.2s infinite alternate;
}
.tg-stars-circle .s1 { top: 0; left: 50%; margin-left: -4px; animation-delay: 0s; }
.tg-stars-circle .s2 { top: 12px; right: 12px; color: #00ffff; animation-delay: 0.2s; }
.tg-stars-circle .s3 { top: 50%; right: 0; margin-top: -4px; animation-delay: 0.4s; }
.tg-stars-circle .s4 { bottom: 12px; right: 12px; color: #ff00ff; animation-delay: 0.6s; }
.tg-stars-circle .s5 { bottom: 0; left: 50%; margin-left: -4px; animation-delay: 0.8s; }
.tg-stars-circle .s6 { bottom: 12px; left: 12px; color: #00ff00; animation-delay: 1s; }
.tg-stars-circle .s7 { top: 50%; left: 0; margin-top: -4px; animation-delay: 1.2s; }
.tg-stars-circle .s8 { top: 12px; left: 12px; color: #ffcc00; animation-delay: 1.4s; }

@keyframes tg-spin-dust { 100% { transform: translate(-50%, -50%) rotate(360deg); } }
@keyframes tg-spin-stars { 100% { transform: translate(-50%, -50%) rotate(-360deg); } }
@keyframes tg-twinkle-dust {
    0% { opacity: 0.3; filter: brightness(0.8); }
    100% { opacity: 1; filter: brightness(1.5) drop-shadow(0 0 2px #fff); }
}
@keyframes tg-star-blink {
    0% { opacity: 0.2; transform: scale(0.5); }
    100% { opacity: 1; transform: scale(1.3); }
}

/* Permanent Popup for Floating Icon */
.tg-popup {
    position: absolute;
    right: calc(100% + 20px);
    top: 50%;
    transform: translateY(-50%);
    background: #ffcc00;
    color: #111;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 800;
    white-space: nowrap;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    pointer-events: none;
    animation: tg-bounce 2s infinite;
    z-index: 20;
    font-family: 'Cairo', sans-serif;
}
.tg-popup::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 8px 0 8px 8px;
    border-style: solid;
    border-color: transparent transparent transparent #ffcc00;
}
@keyframes tg-bounce {
    0%, 100% { transform: translate(0, -50%); }
    50% { transform: translate(-10px, -50%); }
}

/* Permanent Popup for Footer Icon */
.tg-popup-footer {
    position: absolute;
    bottom: calc(100% + 20px);
    left: 50%;
    transform: translateX(-50%);
    background: #ffcc00;
    color: #111;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 800;
    white-space: nowrap;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    pointer-events: none;
    animation: tg-bounce-up 2s infinite;
    z-index: 20;
    font-family: 'Cairo', sans-serif;
}
.tg-popup-footer::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 8px 8px 0 8px;
    border-style: solid;
    border-color: #ffcc00 transparent transparent transparent;
}
@keyframes tg-bounce-up {
    0%, 100% { transform: translate(-50%, 0); }
    50% { transform: translate(-50%, -8px); }
}

/* RTL Popup Fix for Arabic */
[dir="rtl"] .tg-popup {
    left: calc(100% + 20px) !important;
    right: auto !important;
    animation: tg-bounce-rtl 2s infinite !important;
}
[dir="rtl"] .tg-popup::after {
    left: -8px !important;
    right: auto !important;
    border-width: 8px 8px 8px 0 !important;
    border-color: transparent #ffcc00 transparent transparent !important;
}
@keyframes tg-bounce-rtl {
    0%, 100% { transform: translate(0, -50%); }
    50% { transform: translate(10px, -50%); }
}

/* Ensure absolute positioning for stars to prevent layout breaking */
.tg-stars-circle i {
    position: absolute !important;
    display: inline-block !important;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1 !important;
}

/* Telegram Popup Close Button */
.tg-popup, .tg-popup-footer {
    pointer-events: auto !important;
    padding-right: 24px !important;
}
[dir="rtl"] .tg-popup, [dir="rtl"] .tg-popup-footer {
    padding-right: 12px !important;
    padding-left: 24px !important;
}
.close-tg-popup {
    position: absolute;
    top: 4px;
    right: 5px;
    cursor: pointer;
    color: #444;
    font-size: 10px;
    width: 14px;
    height: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(0,0,0,0.05);
    transition: 0.2s;
}
.close-tg-popup:hover {
    color: #000;
    background: rgba(0,0,0,0.15);
    transform: scale(1.1);
}
[dir="rtl"] .close-tg-popup {
    right: auto;
    left: 5px;
}


/* Universal Telegram Fix */
.telegram-magic {
    animation: magic-pulse 2s infinite ease-in-out !important;
    position: relative !important;
    z-index: 10 !important;
    overflow: visible !important;
    isolation: isolate !important;
    transform: translateZ(0) !important;
}
@keyframes magic-pulse {
    0% { box-shadow: 0 0 0 0 rgba(0, 136, 204, 0.8), 0 0 15px rgba(0, 136, 204, 0.6); }
    50% { box-shadow: 0 0 0 15px rgba(0, 136, 204, 0), 0 0 25px rgba(0, 136, 204, 1); }
    100% { box-shadow: 0 0 0 0 rgba(0, 136, 204, 0), 0 0 15px rgba(0, 136, 204, 0.6); }
}


/* Swap Close Button Positions */
.close-tg-popup {
    left: 5px !important;
    right: auto !important;
}
.tg-popup, .tg-popup-footer {
    padding-left: 26px !important;
    padding-right: 14px !important;
}

[dir="rtl"] .close-tg-popup {
    right: 5px !important;
    left: auto !important;
}
[dir="rtl"] .tg-popup, [dir="rtl"] .tg-popup-footer {
    padding-right: 26px !important;
    padding-left: 14px !important;
}


/* Enlarge Close Button (X) */
.close-tg-popup {
    font-size: 14px !important;
    width: 24px !important;
    height: 24px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    background: rgba(0,0,0,0.08) !important;
}
.close-tg-popup:hover {
    transform: translateY(-50%) scale(1.15) !important;
    background: transparent !important;
}

/* Adjust popup padding for larger X */
.tg-popup, .tg-popup-footer {
    padding-left: 34px !important;
    padding-right: 14px !important;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
}
[dir="rtl"] .tg-popup, [dir="rtl"] .tg-popup-footer {
    padding-right: 34px !important;
    padding-left: 14px !important;
}

/* Footer Active Page Indicator */
.footer-link--active {
    color: var(--primary-500) !important;
    font-weight: 800;
    position: relative;
}
.footer-link--active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 25px;
    height: 3px;
    background: var(--primary-500);
    border-radius: 2px;
    box-shadow: 0 0 8px var(--primary-500);
}


/* Hide default black tooltip for Telegram */
.telegram-magic::before {
    display: none !important;
}
.social-float__link:not([data-tooltip])::before,
.social-float__link[data-tooltip=""]::before {
    display: none !important;
}


/* Force Footer Upper Parts to keep the same visual order regardless of language */
html[dir="ltr"] .footer__brand {
    order: 2 !important;
}
html[dir="ltr"] .footer__contact {
    order: 1 !important;
}




/* =========================================
   MOBILE RESPONSIVE HOTFIXES
   ========================================= */
html, body {
    overflow-x: hidden;
    width: 100%;
}
@media (max-width: 768px) {
    .social-float {
        display: none !important; /* Hide floating icons on mobile, use footer instead */
    }
    .navbar__extra {
        display: none !important; /* Hide extra navbar buttons on mobile to prevent overlap */
    }
    .footer {
        padding: 40px 20px !important; /* Better mobile padding */
    }
    .footer__container {
        padding: 0 !important;
        grid-template-columns: 1fr !important; /* Force 1 column footer */
    }
}






/* Shift Telegram Stars for Edge Attached Icons */
[dir="rtl"] .social-float__link--telegram .tg-dust-ring,
[dir="rtl"] .social-float__link--telegram .tg-stars-circle {
    margin-left: 12px;
}
[dir="ltr"] .social-float__link--telegram .tg-dust-ring,
[dir="ltr"] .social-float__link--telegram .tg-stars-circle {
    margin-right: 12px;
}


/* RTL/LTR specific positioning for social float */
[dir="rtl"] .social-float {
    left: 15px;
    right: auto;
}
[dir="ltr"] .social-float {
    right: 15px;
    left: auto;
}


/* Modern Edge Social Icons - Sleek Slide Out */
.social-float {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.social-float__link {
    width: 38px !important;
    height: 42px !important;
    font-size: 1.2rem !important;
}

[dir="rtl"] .social-float__link {
    border-radius: 0 20px 20px 0 !important;
    transform-origin: left center;
    padding-left: 4px;
}
[dir="ltr"] .social-float__link {
    border-radius: 20px 0 0 20px !important;
    transform-origin: right center;
    padding-right: 4px;
}

[dir="rtl"] .social-float {
    left: 0 !important;
    right: auto !important;
    transform: translateX(-4px);
}
[dir="rtl"] .social-float:hover {
    transform: translateX(0);
}

[dir="ltr"] .social-float {
    right: 0 !important;
    left: auto !important;
    transform: translateX(4px);
}
[dir="ltr"] .social-float:hover {
    transform: translateX(0);
}

@media (max-width: 768px) {
    [dir="rtl"] .social-float { transform: translateX(0); }
    [dir="ltr"] .social-float { transform: translateX(0); }
}

/* Ensure Telegram Stars are perfectly centered on the icon */
.social-float__link--telegram .tg-dust-ring,
.social-float__link--telegram .tg-stars-circle {
    top: 50% !important;
    left: 50% !important;
    margin: 0 !important;
}


/* ========== Strategic Partners Section (Homepage) ========== */
.home-partners-section {
    padding: 70px 20px 60px 20px;
    background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    position: relative;
    overflow: hidden;
}

.home-partners-container {
    max-width: 950px;
    margin: 0 auto;
}

.home-partners-title {
    font-size: clamp(2rem, 3.8vw, 2.5rem) !important;
    font-weight: 800 !important;
    text-align: center;
    margin-bottom: 40px !important;
    position: relative;
    display: table;
    margin-left: auto;
    margin-right: auto;
}

.home-partners-stack {
    display: flex;
    flex-direction: column;
    gap: 26px;
    align-items: stretch;
}

.home-partner-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(4, 102, 200, 0.12);
    border-radius: 20px;
    padding: 30px 32px;
    box-shadow: 0 10px 30px rgba(2, 62, 138, 0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    position: relative;
    overflow: hidden;
}

.home-partner-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-700), var(--primary-500), var(--primary-300));
}

.home-partner-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 36px rgba(2, 62, 138, 0.12);
    border-color: rgba(0, 150, 199, 0.35);
}

[data-theme="dark"] .home-partner-card {
    background: linear-gradient(145deg, rgba(17, 34, 64, 0.95) 0%, rgba(13, 27, 51, 0.92) 100%);
    border-color: rgba(72, 202, 228, 0.18);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}

[data-theme="dark"] .home-partner-card:hover {
    border-color: rgba(72, 202, 228, 0.4);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
}

/* Partner 1: Bio Science Lab */
.home-partner-card--bio {
    display: flex;
    align-items: center;
    gap: 24px;
}

.home-partner-card__icon-wrap {
    width: 68px;
    height: 68px;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--primary-600) 0%, var(--primary-800) 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.85rem;
    flex-shrink: 0;
    box-shadow: 0 8px 20px rgba(4, 102, 200, 0.25);
}

.home-partner-card__content {
    flex: 1;
    min-width: 0;
}

.home-partner-card__badge {
    display: inline-block;
    width: fit-content;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--primary-600);
    background: rgba(0, 150, 199, 0.12);
    padding: 3px 12px;
    border-radius: 20px;
    margin-bottom: 8px;
}

[data-theme="dark"] .home-partner-card__badge {
    color: var(--primary-300);
    background: rgba(72, 202, 228, 0.14);
}

.home-partner-card__title {
    font-size: 1.55rem;
    font-weight: 800;
    color: var(--primary-800);
    margin: 0 0 8px 0;
    line-height: 1.35;
}

.home-partner-card__title--bio {
    font-size: 1.7rem;
    letter-spacing: -0.3px;
}

[data-theme="dark"] .home-partner-card__title {
    color: #ffffff;
}

.home-partner-card__desc {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-secondary);
    margin: 0;
}

[data-theme="dark"] .home-partner-card__desc {
    color: #cbd5e1;
}

/* Partner 2: Fermix Factory */
.home-partner-card--fermex {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 36px 32px 32px 32px;
}

.home-partner-card__logo-wrap {
    width: 100%;
    max-width: 290px;
    margin: 0 auto 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.55);
    border-radius: 14px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.04);
}

[data-theme="dark"] .home-partner-card__logo-wrap {
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
}

.home-partner-card__logo {
    max-width: 100%;
    height: auto;
    max-height: 110px;
    object-fit: contain;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.12));
    transition: transform 0.3s ease;
}

.home-partner-card:hover .home-partner-card__logo {
    transform: scale(1.03);
}

/* Footer Link / CTA */
.home-partners-footer {
    text-align: center;
    margin-top: 32px;
}

.home-partners-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 12px 28px;
    border-radius: 30px;
    background: linear-gradient(135deg, var(--primary-700) 0%, var(--primary-600) 100%);
    color: #ffffff !important;
    text-decoration: none;
    font-size: 1.02rem;
    font-weight: 700;
    box-shadow: 0 8px 20px rgba(4, 102, 200, 0.25);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.home-partners-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(4, 102, 200, 0.35);
}

.home-partners-btn__icon {
    font-size: 0.95rem;
    transition: transform 0.25s ease;
}

html[dir="rtl"] .home-partners-btn__icon {
    transform: scaleX(1);
}

html[dir="ltr"] .home-partners-btn__icon {
    transform: rotate(180deg);
}

/* ===== Partners cards: site-color background (overrides) ===== */
.home-partner-card {
    background: linear-gradient(135deg, var(--primary-700) 0%, var(--primary-600) 50%, var(--primary-500) 100%);
    border: none;
    box-shadow: 0 12px 30px rgba(2, 62, 138, 0.28);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}
[data-theme="dark"] .home-partner-card {
    background: linear-gradient(135deg, #0d1b33 0%, #122240 50%, #162a4d 100%);
    border: 1px solid rgba(72, 202, 228, 0.2);
}
.home-partner-card::before { background: linear-gradient(90deg, rgba(255,255,255,0.55), rgba(255,255,255,0.15)); }
.home-partner-card__title,
.home-partner-card__title--bio,
[data-theme="dark"] .home-partner-card__title { color: #ffffff; }
.home-partner-card__desc,
[data-theme="dark"] .home-partner-card__desc { color: rgba(255, 255, 255, 0.9); }
.home-partner-card__badge,
[data-theme="dark"] .home-partner-card__badge { color: #ffffff; background: rgba(255, 255, 255, 0.18); }
.home-partner-card__icon-wrap { background: rgba(255, 255, 255, 0.18); box-shadow: none; }
.home-partner-card__logo-wrap,
[data-theme="dark"] .home-partner-card__logo-wrap { background: transparent; box-shadow: none; }
.home-partner-card__logo { filter: drop-shadow(0 0 14px rgba(255, 255, 255, 0.55)); }

/* ===== Partners heading: larger + decorative effect ===== */
.home-partners-title {
    font-size: clamp(2.8rem, 6vw, 4.2rem) !important;
    font-weight: 900 !important;
    letter-spacing: 1px;
    margin-bottom: 52px !important;
    padding: 0 10px 18px 10px;
    background: linear-gradient(90deg, var(--primary-800), var(--primary-500), var(--primary-700), var(--primary-500));
    background-size: 250% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    filter: drop-shadow(0 6px 14px rgba(0, 119, 182, 0.35));
    animation: partnersTitleShine 5s linear infinite;
}
.home-partners-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 140px;
    height: 5px;
    transform: translateX(-50%);
    border-radius: 10px;
    background: linear-gradient(90deg, transparent, var(--primary-500), var(--primary-300), var(--primary-500), transparent);
    box-shadow: 0 0 14px rgba(0, 180, 216, 0.7);
}
[data-theme="dark"] .home-partners-title {
    background-image: linear-gradient(90deg, var(--primary-300), #ffffff, var(--primary-400), var(--primary-300));
    filter: drop-shadow(0 0 16px rgba(72, 202, 228, 0.55));
}
@keyframes partnersTitleShine {
    0% { background-position: 0% 50%; }
    100% { background-position: 250% 50%; }
}

/* ===== Partners: heading size = welcome title, new font, centered layout ===== */
.home-partners-title {
    font-family: 'Tajawal', 'Cairo', 'Poppins', sans-serif !important;
    font-size: 2.5rem !important;
    letter-spacing: 0;
    margin-bottom: 40px !important;
}
@media (max-width: 992px) { .home-partners-title { font-size: 2rem !important; } }

.home-partner-card,
.home-partner-card--bio,
.home-partner-card--fermex {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 14px;
}
.home-partner-card__content { width: 100%; text-align: center; }
.home-partner-card__icon-wrap { margin: 0 auto; }
.home-partner-card__badge { margin-left: auto; margin-right: auto; }
.home-partner-card__title,
.home-partner-card__desc,
.home-partner-card__badge { font-family: 'Tajawal', 'Cairo', 'Poppins', sans-serif; }
.home-partner-card__desc { margin-left: auto; margin-right: auto; max-width: 680px; }

.home-partners-btn {
    font-family: 'Tajawal', 'Cairo', 'Poppins', sans-serif;
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: 0.3px;
}

/* ===== Partners: remove heading underline + Fermex-style white glow ===== */
.home-partners-title::after,
.home-partners-title.section-title::after { display: none !important; content: none !important; }

.home-partners-title,
[data-theme="dark"] .home-partners-title,
.welcome__title,
[data-theme="dark"] .welcome__title {
    filter: drop-shadow(0 0 14px rgba(255, 255, 255, 0.55));
}
.home-partners-btn {
    filter: drop-shadow(0 0 14px rgba(255, 255, 255, 0.55));
}

/* ===== Footer contact people cards ===== */
.footer-person {
    width: 100%;
    max-width: 280px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 18px 16px;
    background: var(--bg-primary);
    border: 1px solid rgba(4, 102, 200, 0.15);
    border-radius: 16px;
    box-shadow: 0 6px 18px rgba(2, 62, 138, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.footer-person:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(2, 62, 138, 0.16); }
[data-theme="dark"] .footer-person { border-color: rgba(72, 202, 228, 0.2); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35); }
.footer-person__icon {
    width: 46px; height: 46px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--primary-700), var(--primary-500));
    color: #fff; font-size: 1.1rem; margin-bottom: 4px;
}
.footer-person__name { font-weight: 800; font-size: 1.05rem; color: var(--text-primary); }
.footer-person__role { font-size: 0.88rem; color: var(--text-secondary); margin-bottom: 6px; }
.footer-person__phone {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 7px 18px; border-radius: 25px;
    background: linear-gradient(135deg, var(--primary-700), var(--primary-500));
    color: #fff !important; font-weight: 700; font-size: 0.95rem; text-decoration: none;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.footer-person__phone:hover { transform: translateY(-2px); box-shadow: 0 6px 14px rgba(4, 102, 200, 0.35); }

/* ===== Footer people: one horizontal row ===== */
.footer__people {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 10px 20px;
}
.footer__people .footer-person {
    flex: 1 1 240px;
    max-width: 320px;
}
@media (max-width: 768px) {
    .footer__people { flex-direction: column; align-items: center; }
    .footer__people .footer-person { width: 100%; max-width: 340px; flex: 0 0 auto; }
}

/* ===== Footer people: first element in footer ===== */
.footer__people { padding: 50px 20px 0 20px; }
.footer__people + .footer__container { padding-top: 40px !important; }

/* ===== Footer contact title above people ===== */
.footer__people-title {
    text-align: center;
    color: var(--primary-600);
    font-size: 1.5rem;
    font-weight: 800;
    margin: 0 auto;
    padding: 50px 20px 0 20px;
}
.footer__people-title + .footer__people { padding-top: 24px; }
[data-theme="dark"] .footer__people-title { color: var(--primary-300); }

/* ==========================================================================
   Unified Balanced Footer Design (Preserves --bg-footer & Original Card Styles)
   ========================================================================== */
.footer {
    background: var(--bg-footer) !important;
    padding: 40px 20px 22px 20px !important;
    color: var(--text-primary);
}

.footer__inner {
    max-width: 1200px;
    margin: 0 auto;
}

.footer__people-title {
    text-align: center;
    color: var(--primary-700) !important;
    font-size: 1.55rem !important;
    font-weight: 800 !important;
    margin: 0 auto 22px auto !important;
    padding: 0 20px 10px 20px !important;
    position: relative;
}

.footer__people-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 68px;
    height: 3.5px;
    border-radius: 4px;
    background: linear-gradient(90deg, var(--primary-700), var(--primary-500));
}

[data-theme="dark"] .footer__people-title {
    color: var(--primary-300) !important;
}

.footer__people {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 22px !important;
    max-width: 1200px !important;
    margin: 0 auto 36px auto !important;
    padding: 0 !important;
}

.footer__people .footer-person {
    max-width: none !important;
    width: 100% !important;
}

/* 3 Balanced Columns inside the SAME unified footer */
.footer__main-grid {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr 1.15fr;
    gap: 36px;
    align-items: start;
    padding: 34px 0 28px 0;
    border-top: 1px solid rgba(4, 102, 200, 0.16);
    border-bottom: 1px solid rgba(4, 102, 200, 0.16);
    text-align: start;
}

[data-theme="dark"] .footer__main-grid {
    border-color: rgba(255, 255, 255, 0.1);
}

/* Column 1: Brand + Golden Logo */
.footer__brand-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    align-self: center;
    text-align: center;
    gap: 16px;
}

.footer__brand-desc {
    color: var(--text-primary);
    line-height: 1.7;
    font-weight: 800;
    font-size: 1.04rem;
    margin: 0;
    text-align: center;
}

.footer__brand-desc span {
    color: var(--primary-700);
}

[data-theme="dark"] .footer__brand-desc span {
    color: var(--primary-300);
}

/* Column Headings */
.footer__col-title {
    font-size: 1.12rem;
    font-weight: 800;
    color: var(--primary-800);
    margin: 0 0 16px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

[data-theme="dark"] .footer__col-title {
    color: var(--primary-300);
}

.footer__col-title::before {
    content: '';
    width: 4px;
    height: 20px;
    border-radius: 4px;
    background: linear-gradient(180deg, var(--primary-700), var(--primary-500));
    flex-shrink: 0;
}

/* Column 2: Quick Links */
.footer__links-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 9px;
    max-width: 240px;
}

.footer__links-pill {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 8px 14px;
    border-radius: 11px;
    background: var(--bg-primary);
    border: 1px solid rgba(4, 102, 200, 0.15);
    color: var(--text-primary);
    font-size: 0.96rem;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, color 0.22s ease;
}

[data-theme="dark"] .footer__links-pill {
    border-color: rgba(72, 202, 228, 0.2);
}

.footer__links-pill:hover {
    transform: translateX(-4px);
    border-color: var(--primary-500);
    color: var(--primary-700);
    box-shadow: 0 4px 12px rgba(2, 62, 138, 0.1);
}

html[dir="ltr"] .footer__links-pill:hover {
    transform: translateX(4px);
}

[data-theme="dark"] .footer__links-pill:hover {
    color: var(--primary-300);
    border-color: var(--primary-400);
}

.footer__links-pill.active {
    background: linear-gradient(135deg, var(--primary-700), var(--primary-500));
    color: #ffffff !important;
    border-color: transparent;
    box-shadow: 0 4px 12px rgba(4, 102, 200, 0.25);
}

.footer__links-pill i {
    font-size: 0.72rem;
    color: var(--primary-600);
    transition: transform 0.22s ease;
}

html[dir="ltr"] .footer__links-pill i {
    transform: rotate(180deg);
}

[data-theme="dark"] .footer__links-pill i {
    color: var(--primary-300);
}

.footer__links-pill.active i {
    color: #ffffff !important;
}

/* Column 3: Contact Info + Human Health + Original Telegram Magic Socials */
.footer__contact-col {
    display: flex;
    flex-direction: column;
    gap: 11px;
}

.footer__info-pill {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 12px;
    background: var(--bg-primary);
    border: 1px solid rgba(4, 102, 200, 0.15);
    color: var(--text-primary);
    font-size: 0.94rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.22s ease, border-color 0.22s ease;
}

[data-theme="dark"] .footer__info-pill {
    border-color: rgba(72, 202, 228, 0.2);
}

a.footer__info-pill:hover {
    transform: translateY(-2px);
    border-color: var(--primary-500);
}

.footer__info-pill i {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    background: linear-gradient(135deg, var(--primary-700), var(--primary-500));
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.92rem;
    flex-shrink: 0;
}

.footer__human-cta {
    background: linear-gradient(135deg, var(--primary-500), var(--primary-700));
    color: #ffffff !important;
    padding: 11px 18px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.96rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    box-shadow: var(--shadow-sm);
    margin-top: 2px;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.footer__human-cta:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.footer__social-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-top: 62px;
    padding-bottom: 6px;
}

.footer__bottom {
    text-align: center;
    padding: 20px 10px 4px 10px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.footer__bottom-brand {
    color: var(--primary-700);
    font-weight: 700;
    text-decoration: none;
}

[data-theme="dark"] .footer__bottom-brand {
    color: var(--primary-300);
}

@media (max-width: 960px) {
    .footer__main-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }

    .footer__col-title {
        justify-content: center;
    }

    .footer__links-list {
        margin: 0 auto;
        max-width: 290px;
    }

    .footer__contact-col {
        max-width: 360px;
        margin: 0 auto;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .footer__people {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
        max-width: 360px !important;
    }
}
