/* ============================================================
   WEBSTER PETROLEUM - STYLE SHEET (Fully Responsive + Side Menu + Mobile Hero)
   ============================================================ */

/* ----- Reset & Variables ----- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --dark-navy: #071C3A;
    --dark-navy-light: #0a2a55;
    --gold: #C8A14A;
    --gold-light: #D4B05A;
    --light-gray: #F5F6F8;
    --text-primary: #1F2937;
    --text-secondary: #6B7280;
    --border-radius: 16px;
    --header-height: 80px;
    --transition-smooth: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-primary);
    background: #FFF;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    word-wrap: break-word;
    overflow-wrap: break-word;
    cursor: default;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ----- RTL / LTR ----- */
[dir="rtl"] { direction: rtl; text-align: right; }
[dir="ltr"] { direction: ltr; text-align: left; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ----- Loading Screen ----- */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--dark-navy);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}
#loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}
.loader {
    text-align: center;
}
.loader-ring {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(200, 161, 74, 0.2);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
.loader-text {
    color: #FFF;
    font-family: 'Montserrat', sans-serif;
    font-weight: 900;
    font-size: 1.5rem;
    letter-spacing: 8px;
    color: var(--gold);
}

/* ----- Typography ----- */
h1, h2, h3, h4 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    color: var(--dark-navy);
    line-height: 1.2;
}
h1 { font-size: 4rem; }
h2 { font-size: 2.8rem; margin-bottom: 20px; }
h3 { font-size: 1.6rem; }
p { color: var(--text-secondary); line-height: 1.8; }
.gold-text { color: var(--gold); }

/* ----- Spacing بين الأقسام ----- */
.section { padding: 120px 0; }

/* ============================================================
   HEADER (Navbar زجاجي)
   ============================================================ */
#main-header {
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    padding: 0 15px;
    z-index: 9999;
    height: var(--header-height);
    display: flex;
    align-items: center;
    transition: all 0.5s ease;
    background: transparent;
}

/* 🔥 طبقة تدرج داكنة خلف الهيدر لضمان وضوح اللوجو والقائمة فوق أي محتوى */
#main-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg,
        rgba(7, 28, 58, 0.85) 0%,
        rgba(7, 28, 58, 0.55) 55%,
        rgba(7, 28, 58, 0) 100%);
    pointer-events: none;
    z-index: -1;
    transition: opacity 0.4s ease;
}

/* عند التمرير: نخفي التدرج لأن الهيدر أصبح زجاجياً */
#main-header.scrolled::before {
    opacity: 0;
}

#main-header.scrolled {
    background: rgba(4, 26, 53, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.15);
    height: 70px;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}
.logo-img {
    height: 50px;
    width: auto;
    transition: 0.3s;
}
#main-header.scrolled .logo-img {
    height: 42px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lang-btn {
    background: transparent;
    color: #FFF;
    padding: 6px 16px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 13px;
    transition: 0.3s;
    border: 2px solid var(--gold);
}
.lang-btn:hover {
    background: var(--gold);
    color: var(--dark-navy);
    transform: scale(1.03);
}

/* هامبرغر */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    padding: 5px;
    z-index: 1001;
}
.hamburger span {
    width: 28px;
    height: 2.5px;
    background: #FFF;
    border-radius: 3px;
    transition: 0.3s;
}
#main-header.scrolled .hamburger span {
    background: #FFF;
}

/* ===== تحسين مظهر الروابط في الهيدر (احترافي) ===== */
#main-header nav a {
    color: rgba(255, 255, 255, 0.85);
    padding: 8px 18px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    font-size: 15px;
    border-radius: 8px;
    position: relative;
}

#main-header nav a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

#main-header nav a:hover::after,
#main-header nav a.active::after {
    width: 60%;
}

#main-header nav a:hover {
    color: var(--gold);
    background: rgba(200, 161, 74, 0.08);
}

#main-header nav a.active {
    color: var(--gold);
    background: rgba(200, 161, 74, 0.12);
}

.nav-cta {
    border: 2px solid var(--gold) !important;
    padding: 8px 22px !important;
    border-radius: 50px !important;
    background: transparent !important;
    color: #FFF !important;
}

.nav-cta:hover {
    background: var(--gold) !important;
    color: var(--dark-navy) !important;
}

.nav-cta::after {
    display: none !important;
}

.nav-cta.active {
    background: var(--gold) !important;
    color: var(--dark-navy) !important;
}

/* ===== القائمة الجانبية (Side Menu) ===== */
#side-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
}
#side-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

#side-menu {
    position: fixed;
    top: 0;
    right: -320px;
    width: 300px;
    height: 100%;
    background: linear-gradient(180deg, #071C3A 0%, #0a2a55 100%);
    z-index: 1002;
    transition: right 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    padding: 30px 25px;
    display: flex;
    flex-direction: column;
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.3);
}
#side-menu.open {
    right: 0;
}

.side-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 30px;
}
.side-logo {
    height: 45px;
    width: auto;
}
.side-menu-close {
    background: transparent;
    border: none;
    color: #FFF;
    font-size: 28px;
    cursor: pointer;
    transition: 0.3s;
    padding: 0 5px;
}
.side-menu-close:hover {
    color: var(--gold);
    transform: rotate(90deg);
}

.side-menu-nav {
    display: flex;
    flex-direction: column;
    gap: 5px;
    flex: 1;
}
.side-menu-nav a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 18px;
    font-weight: 500;
    padding: 14px 18px;
    border-radius: 12px;
    transition: 0.3s;
    border-left: 3px solid transparent;
}
.side-menu-nav a:hover {
    background: rgba(200, 161, 74, 0.15);
    color: var(--gold);
    border-left-color: var(--gold);
    padding-left: 25px;
}
.side-nav-cta {
    background: var(--gold) !important;
    color: #FFF !important;
    text-align: center;
    border-left: none !important;
    margin-top: 15px;
    font-weight: 600 !important;
}
.side-nav-cta:hover {
    background: #FFF !important;
    color: var(--dark-navy) !important;
    padding-left: 18px !important;
}

.side-menu-footer {
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 20px;
}
.side-menu-footer p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
    line-height: 1.8;
    margin: 0;
}

/* ============================================================
   HERO SECTION (مع صورة مخصصة للهواتف + تأثير Ken Burns)
   ============================================================ */
.hero-section {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: calc(var(--header-height) + 20px);
    padding-bottom: 40px;
    position: relative;
    overflow: hidden;
    z-index: 1;
    margin: 0;
    width: 100%;
}

/* خلفية الهيرو - الصورة الأساسية للكمبيوتر */
.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: url('hero-bg.jpg') center center / cover no-repeat;
    animation: kenBurnsZoom 20s ease-in-out infinite;
}
@keyframes kenBurnsZoom {
    0% {
        transform: scale(1.1);
    }
    50% {
        transform: scale(1.0);
    }
    100% {
        transform: scale(1.1);
    }
}

/* ===== صورة مخصصة للهواتف مع تأثير Ken Burns ===== */
@media (max-width: 768px) {
    .hero-bg {
        background: url('hero-bg-mobile.jpg') center center / cover no-repeat !important;
        animation: kenBurnsZoom 20s ease-in-out infinite !important;
    }
}

@media (max-width: 480px) {
    .hero-bg {
        background: url('hero-bg-mobile.jpg') top center / cover no-repeat !important;
        animation: kenBurnsZoom 20s ease-in-out infinite !important;
    }
}

/* ===== صورة مخصصة لقسم الرؤية للهواتف ===== */
@media (max-width: 768px) {
    .vision-section {
        background: linear-gradient(rgba(7, 28, 58, 0.85), rgba(7, 28, 58, 0.95)), url('vision-bg-mobile.jpg') center center / cover no-repeat !important;
        background-attachment: scroll !important;
    }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(7, 28, 58, 0.55);
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 15px;
}
.hero-content h1 {
    color: #FFF;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(50px);
    animation: fadeUp 0.8s ease 0.3s forwards;
}
.hero-content p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 20px;
    opacity: 0;
    transform: translateY(50px);
    animation: fadeUp 0.8s ease 0.6s forwards;
}
.hero-content .hero-buttons {
    opacity: 0;
    transform: translateY(50px);
    animation: fadeUp 0.8s ease 0.9s forwards;
}
.hero-content .btn-secondary {
    border-color: #FFF;
    color: #FFF;
    margin-right: 15px;
}
.hero-content .btn-secondary:hover {
    background: #FFF;
    color: var(--dark-navy);
}

/* Typing Effect */
.typing-wrapper {
    display: inline-block;
    min-height: 60px;
    opacity: 0;
    transform: translateY(50px);
    animation: fadeUp 0.8s ease 0.7s forwards;
}
#typed-text {
    color: var(--gold);
    border-bottom: 3px solid var(--gold);
    padding-bottom: 5px;
}
.typing-cursor {
    display: inline-block;
    width: 4px;
    height: 1.2em;
    background-color: var(--gold);
    margin-left: 5px;
    vertical-align: text-bottom;
    animation: blink 0.8s step-end infinite;
}
@keyframes blink {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0;
    }
}

@keyframes fadeUp {
    0% {
        opacity: 0;
        transform: translateY(50px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ----- الأزرار ----- */
.btn-primary {
    background: var(--gold);
    color: #FFF;
    padding: 16px 45px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    transition: all 0.4s ease;
    border: 2px solid var(--gold);
    text-align: center;
    position: relative;
    overflow: hidden;
}
.btn-primary:hover {
    background: var(--dark-navy);
    color: var(--gold);
    border-color: var(--dark-navy);
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 15px 40px rgba(200, 161, 74, 0.3);
}
.btn-primary .ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    transform: scale(0);
    animation: rippleAnim 0.6s linear;
    pointer-events: none;
}
@keyframes rippleAnim {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--gold);
    color: var(--gold);
    padding: 14px 38px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.4s ease;
    display: inline-block;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.btn-secondary:hover {
    background: var(--gold);
    color: #FFF;
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 15px 40px rgba(200, 161, 74, 0.2);
}

/* ============================================================
   VISION SECTION
   ============================================================ */
.vision-section {
    background: linear-gradient(rgba(7, 28, 58, 0.85), rgba(7, 28, 58, 0.95)), url('vision-bg.jpg') center center / cover no-repeat;
    position: relative;
    z-index: 2;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.3);
    padding-top: 120px;
    padding-bottom: 120px;
    background-attachment: fixed;
    background-position: center;
    background-size: cover;
}
.vision-section h2,
.vision-section p {
    color: #FFF !important;
}

/* ============================================================
   CARDS
   ============================================================ */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}
.card {
    background: #FFF;
    padding: 35px 30px;
    border-radius: var(--border-radius);
    border: 1px solid #E5E7EB;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    text-align: center;
}
.card:hover {
    transform: translateY(-12px);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.1);
    border-color: var(--gold);
}
.card-icon {
    font-size: 45px;
    color: var(--gold);
    margin-bottom: 15px;
    display: block;
    transition: transform 0.3s ease;
}
.card:hover .card-icon {
    transform: scale(1.1) rotate(-5deg);
}
.card h3 {
    color: var(--dark-navy);
    margin-bottom: 10px;
}
.card p {
    color: var(--text-secondary);
}

/* ============================================================
   STATS / ANIMATED NUMBERS
   ============================================================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 40px;
    text-align: center;
}
.stat-item .stat-number {
    font-size: 4rem;
    font-weight: 900;
    color: var(--gold);
    display: block;
    font-family: 'Montserrat', sans-serif;
    line-height: 1;
}
.stat-item p {
    color: #D1D5DB;
    font-weight: 500;
    margin-top: 10px;
    font-size: 1.1rem;
}

/* ============================================================
   IMAGE ZOOM
   ============================================================ */
.img-zoom {
    border-radius: var(--border-radius);
    overflow: hidden;
}
.img-zoom img {
    transition: transform 0.6s ease, opacity 0.6s ease;
    transform: scale(0.92);
    opacity: 0.9;
}
.img-zoom img.aos-animate {
    transform: scale(1);
    opacity: 1;
}
.img-zoom:hover img {
    transform: scale(1.05);
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
    background: linear-gradient(135deg, #02152D, #061F40);
    color: #9CA3AF;
    padding: 60px 0 20px;
    position: relative;
    overflow: hidden;
}
footer::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 50%, rgba(200, 161, 74, 0.03) 0%, transparent 60%);
    pointer-events: none;
}
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    position: relative;
    z-index: 1;
}
footer h3,
footer h4 {
    color: #FFF !important;
}
footer a {
    color: #9CA3AF;
    text-decoration: none;
    transition: 0.3s;
    line-height: 2.2;
}
footer a:hover {
    color: var(--gold);
    transform: translateX(5px);
}
.footer-logo {
    height: 60px;
    width: auto;
    margin-bottom: 15px;
}

/* ================================================================
   ================================================================
   RESPONSIVE - جميع الأجهزة
   ================================================================
   ================================================================ */

/* ===== 1. شاشات كبيرة جداً (تلفزيونات 4K, 1400px+) ===== */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
        padding: 0 40px;
    }
    h1 {
        font-size: 5rem;
    }
    h2 {
        font-size: 3.5rem;
    }
    h3 {
        font-size: 2rem;
    }
    .section {
        padding: 150px 0;
    }
    .hero-content {
        max-width: 1100px;
    }
    .hero-content p {
        font-size: 1.4rem;
        max-width: 800px;
    }
    .btn-primary,
    .btn-secondary {
        padding: 18px 55px;
        font-size: 1.1rem;
    }
    .stats-grid {
        gap: 60px;
    }
    .stat-item .stat-number {
        font-size: 5rem;
    }
    .cards-grid {
        gap: 40px;
    }
    .card {
        padding: 45px 40px;
    }
}

/* ===== 2. أجهزة الكمبيوتر المكتبي (992px - 1399px) ===== */
@media (max-width: 1399px) and (min-width: 993px) {
    h1 {
        font-size: 3.8rem;
    }
    h2 {
        font-size: 2.6rem;
    }
    .section {
        padding: 110px 0;
    }
}

/* ===== 3. تابلت / لابتوب (769px - 992px) ===== */
@media (max-width: 992px) {
    .hamburger {
        display: flex;
    }
    #main-header nav {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: center;
        padding: 20px 0 30px;
        background: rgba(4, 26, 53, 0.95);
        backdrop-filter: blur(15px);
        border-radius: 0 0 20px 20px;
        order: 3;
        gap: 5px;
    }
    #main-header nav.open {
        display: flex;
    }
    #main-header nav a {
        width: 100%;
        text-align: center;
        padding: 12px;
        color: #FFF;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        font-size: 16px;
    }
    #main-header nav a::after {
        display: none;
    }
    .nav-cta {
        color: #FFF !important;
    }

    h1 {
        font-size: 2.8rem;
    }
    h2 {
        font-size: 2.2rem;
    }
    .section {
        padding: 80px 0;
    }
    .hero-section {
        min-height: 90vh;
    }
    .hero-content p {
        font-size: 1.1rem;
    }
    .vision-section {
        padding-top: 80px;
        padding-bottom: 80px;
        background-attachment: scroll;
    }
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    .stat-item .stat-number {
        font-size: 3.5rem;
    }
    .cards-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    #side-menu {
        width: 280px;
        right: -290px;
    }
}

/* ===== 4. هواتف كبيرة / تابلت صغير (481px - 768px) ===== */
@media (max-width: 768px) {
    :root {
        --header-height: 65px;
    }

    /* 🔥 إصلاح تداخل الهيدر على الهاتف 🔥 */
    .header-container {
        display: grid !important;
        grid-template-columns: 1fr auto;
        align-items: center;
        width: 100%;
    }
    .logo {
        justify-self: start;
    }
    .header-right {
        justify-self: end;
        display: flex;
        align-items: center;
        gap: 10px;
    }
    #main-header nav {
        display: none !important;
    }
    .lang-btn {
        white-space: nowrap;
        font-size: 12px;
        padding: 5px 14px;
    }
    .logo-img {
        max-height: 38px;
        width: auto;
    }

    /* 🔥 زيادة التدرج خلف الهيدر على الهاتف لضمان وضوح أكبر */
    #main-header::before {
        height: 180%;
        background: linear-gradient(180deg,
            rgba(7, 28, 58, 0.95) 0%,
            rgba(7, 28, 58, 0.75) 40%,
            rgba(7, 28, 58, 0.35) 70%,
            rgba(7, 28, 58, 0) 100%);
    }
    /* ======================================================== */

    #main-header.scrolled .logo-img {
        height: 32px;
    }
    #main-header.scrolled {
        height: 60px;
    }
    #main-header {
        padding: 0 12px;
    }

    /* 🔥 زيادة المسافة العلوية للهيرو على الهاتف لمنع التداخل */
    .hero-section {
        padding-top: calc(var(--header-height) + 40px);
        padding-bottom: 50px;
        min-height: 90vh;
        align-items: flex-start;
    }

    h1 {
        font-size: 2.2rem;
    }
    h2 {
        font-size: 1.8rem;
    }
    h3 {
        font-size: 1.3rem;
    }
    p {
        font-size: 0.95rem;
    }
    .section {
        padding: 60px 0;
    }

    .hero-content p {
        font-size: 1rem;
        max-width: 100%;
    }
    .typing-wrapper {
        min-height: 40px;
    }
    .typing-wrapper span {
        font-size: 1.2rem !important;
    }
    #typed-text {
        font-size: 1.2rem !important;
    }

    .btn-primary,
    .btn-secondary {
        padding: 14px 30px;
        font-size: 0.95rem;
        width: 100%;
        max-width: 280px;
        margin: 8px auto;
        display: block;
    }
    .hero-content .btn-secondary {
        margin-right: 0;
    }
    .hero-buttons {
        gap: 10px !important;
    }

    .cards-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .card {
        padding: 25px 20px;
        max-width: 100%;
        width: 100%;
    }
    .card-icon {
        font-size: 35px;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 20px;
    }
    .stat-item .stat-number {
        font-size: 2.8rem;
    }
    .stat-item p {
        font-size: 0.9rem;
    }

    .vision-section {
        padding-top: 60px;
        padding-bottom: 60px;
        margin-top: 0;
    }

    .container>div[style*="display: flex"] {
        gap: 30px !important;
    }
    .container>div[style*="display: flex"]>div {
        flex: 1 1 100% !important;
        min-width: 100% !important;
        width: 100% !important;
    }
    .img-zoom img {
        height: 220px !important;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 25px;
    }
    .footer-logo {
        margin: 0 auto 15px;
    }
    footer a:hover {
        transform: none;
    }

    .loader-text {
        font-size: 1.2rem;
        letter-spacing: 5px;
    }
    .loader-ring {
        width: 45px;
        height: 45px;
    }

    #side-menu {
        width: 280px;
        right: -290px;
    }
    .side-menu-nav a {
        font-size: 16px;
        padding: 12px 16px;
    }
    .side-logo {
        height: 38px;
    }

    /* 🔥 تحسينات صفحة الشراكة على الهاتف 🔥 */
    .partnership-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    
    .partnership-grid .card {
        padding: 20px !important;
    }
    
    .partnership-core-grid {
        padding: 30px 20px !important;
    }
    
    .partnership-core-grid > div {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }
    
    .partnership-core-grid > div div {
        padding: 15px 20px !important;
    }
}

/* ===== 5. هواتف صغيرة جداً (أقل من 480px) ===== */
@media (max-width: 480px) {
    :root {
        --header-height: 60px;
    }
    .container {
        padding: 0 12px;
    }

    .logo-img {
        height: 32px;
    }
    #main-header.scrolled .logo-img {
        height: 28px;
    }
    #main-header {
        padding: 0 10px;
    }
    .lang-btn {
        font-size: 11px;
        padding: 4px 12px;
    }

    h1 {
        font-size: 1.8rem;
    }
    h2 {
        font-size: 1.5rem;
    }
    h3 {
        font-size: 1.1rem;
    }
    .section {
        padding: 40px 0;
    }

    .hero-section {
        padding-top: calc(var(--header-height) + 35px);
        min-height: 88vh;
    }
    .hero-content p {
        font-size: 0.9rem;
    }
    .typing-wrapper span {
        font-size: 1rem !important;
    }
    #typed-text {
        font-size: 1rem !important;
    }
    .typing-cursor {
        height: 0.9em;
    }

    .btn-primary,
    .btn-secondary {
        padding: 12px 20px;
        font-size: 0.85rem;
        max-width: 100%;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 15px;
    }
    .stat-item .stat-number {
        font-size: 2rem;
    }
    .stat-item p {
        font-size: 0.8rem;
    }

    .card {
        padding: 20px 15px;
    }
    .card-icon {
        font-size: 28px;
    }
    .card h3 {
        font-size: 1rem;
    }
    .card p {
        font-size: 0.85rem;
    }

    .vision-section {
        padding: 40px 0;
    }
    .vision-section div[style*="padding: 30px"] {
        padding: 20px !important;
    }

    footer {
        padding: 40px 0 15px;
    }
    .footer-grid {
        gap: 20px;
    }
    footer h4 {
        font-size: 1rem;
    }
    footer a,
    footer p {
        font-size: 0.85rem;
    }
    .footer-logo {
        height: 45px;
    }

    .loader-text {
        font-size: 1rem;
        letter-spacing: 3px;
    }
    .loader-ring {
        width: 35px;
        height: 35px;
    }

    #side-menu {
        width: 260px;
        right: -270px;
        padding: 20px 18px;
    }
    .side-menu-nav a {
        font-size: 15px;
        padding: 10px 14px;
    }
    .side-menu-header {
        padding-bottom: 18px;
        margin-bottom: 20px;
    }
    .side-menu-close {
        font-size: 24px;
    }
}

/* ===== 6. هواتف صغيرة جداً (أقل من 360px) ===== */
@media (max-width: 360px) {
    .container {
        padding: 0 10px;
    }
    h1 {
        font-size: 1.5rem;
    }
    h2 {
        font-size: 1.2rem;
    }
    .section {
        padding: 30px 0;
    }
    .hero-section {
        padding-top: calc(var(--header-height) + 30px);
        min-height: 85vh;
    }
    .hero-content p {
        font-size: 0.8rem;
    }
    .stat-item .stat-number {
        font-size: 1.6rem;
    }
    .card {
        padding: 15px 12px;
    }
    .card-icon {
        font-size: 24px;
    }
    .btn-primary,
    .btn-secondary {
        padding: 10px 16px;
        font-size: 0.8rem;
    }
    .typing-wrapper span {
        font-size: 0.85rem !important;
    }
    #typed-text {
        font-size: 0.85rem !important;
    }
    #side-menu {
        width: 240px;
        right: -250px;
        padding: 15px;
    }
    .side-menu-nav a {
        font-size: 14px;
        padding: 8px 12px;
    }
}

/* ============================================================
   AOS & SCROLL ANIMATIONS
   ============================================================ */
[data-aos] {
    pointer-events: none;
}
[data-aos].aos-animate {
    pointer-events: auto;
}

/* ============================================================
   تحسينات إضافية للشاشات المتوسطة
   ============================================================ */
@media (min-width: 769px) and (max-width: 1024px) {
    .cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .hero-content h1 {
        font-size: 3rem;
    }
}

/* تحسين لعرض الهواتف في الوضع الأفقي (Landscape) */
@media (max-width: 768px) and (orientation: landscape) {
    .hero-section {
        min-height: 100vh;
        padding-top: calc(var(--header-height) + 20px);
    }
    .hero-content {
        padding: 20px 0;
    }
    .hero-content h1 {
        font-size: 2.5rem;
    }
    .section {
        padding: 50px 0;
    }
}

/* تحسين للطباعة */
@media print {
    #main-header,
    #loading-screen,
    .hero-bg,
    .hero-overlay {
        display: none;
    }
    .hero-section {
        min-height: auto;
        padding: 40px 0;
        background: #FFF;
    }
    .hero-content h1,
    .hero-content p {
        color: #000 !important;
    }
    .section {
        padding: 30px 0;
    }
    .card {
        break-inside: avoid;
        border: 1px solid #CCC;
    }
    footer {
        background: #EEE;
        color: #000;
    }
    .btn-primary,
    .btn-secondary {
        display: none;
    }
}