/* ============================================================
   Dr. Einas Abdulaziz Abood — Personal Website
   Palette: Gochujang Red #780000 · Crimson Blaze #C1121F
            Varden #AE1F23 (on cream) · Cosmos Blue #003049
            Blue Marble #669BBC
   Pure CSS — no frameworks
   ============================================================ */

/* ---------- متغيرات الهوية ---------- */
:root {
    --gochujang: #780000;
    --crimson: #C1121F;
    --varden: #AE1F23;
    --cosmos: #003049;
    --marble: #669BBC;
    --cream: #FDF6E4;
    --cream-2: #F6EDD8;

    --radius: 16px;
    --radius-lg: 24px;
    --shadow: 0 10px 30px rgba(0, 48, 73, .10);
    --shadow-lg: 0 20px 50px rgba(0, 48, 73, .18);
    --font-ar: "Segoe UI", "Noto Kufi Arabic", "Tahoma", sans-serif;
    --font-en: "Georgia", "Times New Roman", serif;
    --font-ui: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    --transition: .35s cubic-bezier(.2, .7, .3, 1);
}

/* ---------- الوضع النهاري (افتراضي) ---------- */
:root, [data-theme="light"] {
    --bg: var(--cream);
    --bg-alt: var(--cream-2);
    --surface: #FFFFFF;
    --text: #22303A;
    --text-soft: #55636D;
    --heading: var(--cosmos);
    --accent: var(--crimson);
    --accent-deep: var(--gochujang);
    --accent-soft: rgba(193, 18, 31, .08);
    --line: rgba(0, 48, 73, .12);
    --header-bg: rgba(253, 246, 228, .85);
}

/* ---------- الوضع الليلي ---------- */
[data-theme="dark"] {
    --bg: #02141F;
    --bg-alt: #032434;
    --surface: #07364E;
    --text: #E9E2D0;
    --text-soft: #A9BCC9;
    --heading: #F3ECDA;
    --accent: #E84855;
    --accent-deep: var(--crimson);
    --accent-soft: rgba(102, 155, 188, .14);
    --line: rgba(233, 226, 208, .14);
    --header-bg: rgba(2, 20, 31, .85);
    --shadow: 0 10px 30px rgba(0, 0, 0, .35);
    --shadow-lg: 0 20px 50px rgba(0, 0, 0, .5);
}

/* ---------- أساسيات ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; scroll-padding-top: 90px; }

body {
    font-family: var(--font-ui);
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    transition: background var(--transition), color var(--transition);
    overflow-x: hidden;
}
[dir="rtl"] body { font-family: var(--font-ar); }
[dir="ltr"] body h1, [dir="ltr"] body h2, [dir="ltr"] body h3, [dir="ltr"] body .hero-name { font-family: var(--font-en); }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

.container { width: min(1140px, 92%); margin-inline: auto; }

/* ---------- تبديل اللغة: إظهار/إخفاء ---------- */
[dir="rtl"] .l-en, [dir="ltr"] .l-ar { display: none !important; }
.l { display: inline; }
p > .l, h1 > .l, h2 > .l, h3 > .l, blockquote > .l, button > .l, a > .l, .insight-meta .l { display: block; }

/* ---------- الترويسة ---------- */
.site-header {
    position: fixed; inset-inline: 0; top: 0; z-index: 100;
    background: var(--header-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid transparent;
    transition: var(--transition);
}
.site-header.scrolled { border-bottom-color: var(--line); box-shadow: var(--shadow); }

.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .9rem 0; }

.brand { display: flex; align-items: center; gap: .7rem; }
.brand-mark {
    width: 42px; height: 42px; border-radius: 12px;
    display: grid; place-items: center;
    background: linear-gradient(135deg, var(--crimson), var(--gochujang));
    color: var(--cream); font-weight: 800; font-size: 1.05rem;
    font-family: var(--font-en);
    box-shadow: var(--shadow);
}
.brand-name { font-weight: 700; font-size: .95rem; color: var(--heading); }
@media (max-width: 720px) { .brand-name { display: none; } }

.main-nav { display: flex; gap: 1.4rem; }
.nav-link {
    position: relative; font-size: .92rem; font-weight: 600;
    color: var(--text-soft); padding: .3rem 0; transition: color .25s;
}
.nav-link::after {
    content: ""; position: absolute; bottom: -2px; inset-inline-start: 0;
    width: 0; height: 2px; border-radius: 2px;
    background: var(--accent); transition: width .3s;
}
.nav-link:hover, .nav-link.active { color: var(--accent); }
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

.header-tools { display: flex; align-items: center; gap: .55rem; }
.tool-btn {
    border: 1px solid var(--line); background: var(--surface);
    color: var(--text); border-radius: 10px; min-width: 40px; height: 40px;
    display: grid; place-items: center; padding: 0 .65rem;
    font-weight: 700; font-size: .82rem; transition: var(--transition);
}
.tool-btn:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }

[data-theme="light"] .icon-moon { display: none; }
[data-theme="dark"] .icon-sun { display: none; }
[dir="rtl"] .lang-label-en { display: none; }
[dir="ltr"] .lang-label-ar { display: none; }

.nav-burger { display: none; flex-direction: column; gap: 5px; }
.nav-burger span { width: 20px; height: 2px; background: currentColor; border-radius: 2px; transition: .3s; }
.nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 860px) {
    .nav-burger { display: flex; }
    .main-nav {
        position: fixed; top: 68px; inset-inline: 4%;
        flex-direction: column; gap: 0;
        background: var(--surface); border: 1px solid var(--line);
        border-radius: var(--radius); box-shadow: var(--shadow-lg);
        padding: .6rem; opacity: 0; pointer-events: none;
        transform: translateY(-12px); transition: var(--transition);
    }
    .main-nav.open { opacity: 1; pointer-events: auto; transform: translateY(0); }
    .nav-link { padding: .8rem 1rem; border-radius: 10px; }
    .nav-link:hover { background: var(--accent-soft); }
    .nav-link::after { display: none; }
}

/* ---------- Hero + سلايدر الخلفية البلوري ---------- */
.hero {
    position: relative; min-height: 100svh;
    display: flex; align-items: center;
    padding: 8rem 0 4rem; overflow: hidden;
}
.hero-slider { position: absolute; inset: 0; z-index: 0; }
.hero-slide {
    position: absolute; inset: 0;
    background-size: cover; background-position: center;
    opacity: 0; transform: scale(1.06);
    transition: opacity 1.6s ease, transform 7s ease;
}
.hero-slide.active { opacity: 1; transform: scale(1); }
.hero-slide::after {
    content: ""; position: absolute; inset: 0;
    backdrop-filter: blur(22px) saturate(1.1);
    -webkit-backdrop-filter: blur(22px) saturate(1.1);
    background: linear-gradient(160deg, rgba(253,246,228,.82), rgba(253,246,228,.68) 45%, rgba(253,246,228,.85));
}
[data-theme="dark"] .hero-slide::after {
    background: linear-gradient(160deg, rgba(2,20,31,.85), rgba(2,20,31,.7) 45%, rgba(2,20,31,.88));
}
.hero-dots {
    position: absolute; bottom: 5.2rem; inset-inline-start: 50%; transform: translateX(50%);
    display: flex; gap: .55rem; z-index: 3;
}
[dir="ltr"] .hero-dots { transform: translateX(-50%); }
.hero-dots button {
    width: 11px; height: 11px; border-radius: 999px; border: none;
    background: var(--line); transition: var(--transition); padding: 0;
}
.hero-dots button.active { width: 30px; background: var(--crimson); }

.hero-bg { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
.blob { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .5; animation: float 12s ease-in-out infinite; }
.b1 { width: 480px; height: 480px; background: rgba(193, 18, 31, .22); top: -140px; inset-inline-start: -120px; }
.b2 { width: 420px; height: 420px; background: rgba(102, 155, 188, .35); bottom: -120px; inset-inline-end: -100px; animation-delay: -4s; }
.b3 { width: 300px; height: 300px; background: rgba(0, 48, 73, .18); top: 40%; inset-inline-start: 45%; animation-delay: -8s; }
@keyframes float { 0%,100% { transform: translateY(0) scale(1); } 50% { transform: translateY(-30px) scale(1.06); } }

.hero-inner {
    position: relative; display: grid;
    grid-template-columns: 1.15fr .85fr; gap: 3.5rem; align-items: center;
}
@media (max-width: 900px) { .hero-inner { grid-template-columns: 1fr; text-align: center; } }

.hero-kicker {
    display: inline-block; font-size: .85rem; font-weight: 700;
    letter-spacing: .06em; color: var(--accent);
    background: var(--accent-soft); border: 1px solid var(--accent);
    padding: .4rem 1rem; border-radius: 999px; margin-bottom: 1.2rem;
}
.hero-name { font-size: clamp(2.1rem, 5vw, 3.6rem); color: var(--heading); line-height: 1.15; font-weight: 800; }
.hero-role { font-size: clamp(1.15rem, 2.4vw, 1.6rem); color: var(--accent); font-weight: 700; margin-top: .4rem; }
.hero-position { font-size: .95rem; font-weight: 600; letter-spacing: .4px; color: var(--text-soft); margin-top: .3rem; text-transform: uppercase; }
.hero-philosophy {
    font-size: 1.12rem; font-weight: 600; color: var(--heading);
    margin-top: 1.3rem; font-style: italic;
}
.hero-sub { color: var(--text-soft); max-width: 54ch; margin-top: .8rem; font-size: 1.02rem; }
@media (max-width: 900px) { .hero-sub { margin-inline: auto; } }

.hero-cta { display: flex; gap: .9rem; margin-top: 1.8rem; flex-wrap: wrap; }
@media (max-width: 900px) { .hero-cta { justify-content: center; } }

.hero-social { display: flex; gap: .7rem; margin-top: 1.6rem; }
@media (max-width: 900px) { .hero-social { justify-content: center; } }

.hero-academic { margin-top: 1.3rem; }
.academic-label {
    display: inline-flex; align-items: center; gap: .6rem;
    font-size: .8rem; font-weight: 700; letter-spacing: .06em;
    color: var(--text-soft); margin-bottom: .7rem;
}
.academic-label::after {
    content: ""; width: 60px; height: 1px;
    background: linear-gradient(90deg, var(--crimson), transparent);
}
[dir="ltr"] .academic-label::after { background: linear-gradient(90deg, var(--crimson), transparent); }
[dir="rtl"] .academic-label::after { background: linear-gradient(-90deg, var(--crimson), transparent); }
.academic-row { display: flex; gap: .7rem; flex-wrap: wrap; }
@media (max-width: 900px) { .academic-row { justify-content: center; } .hero-academic { text-align: center; } }
.academic-btn { border-style: dashed; }
.academic-btn:hover { border-style: solid; }
.social-btn {
    width: 42px; height: 42px; border-radius: 12px;
    display: grid; place-items: center;
    border: 1px solid var(--line); background: var(--surface);
    color: var(--text-soft); transition: var(--transition);
}
.social-btn:hover { background: var(--accent); border-color: var(--accent); color: #fff; transform: translateY(-3px); }

.hero-visual { position: relative; display: flex; justify-content: center; z-index: 2; }
.hero-photo-frame {
    position: relative; width: min(400px, 82vw);
    border-radius: 28px; padding: 12px;
    background: linear-gradient(150deg, var(--crimson), var(--gochujang) 45%, var(--cosmos));
    box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255,255,255,.15) inset;
}
.hero-photo-frame::before {
    content: ""; position: absolute; inset: -14px; z-index: -1;
    border-radius: 36px; border: 2px dashed var(--marble); opacity: .55;
    animation: spinSlow 26s linear infinite;
}
.hero-photo-frame::after {
    content: ""; position: absolute; top: -18px; inset-inline-end: -18px;
    width: 76px; height: 76px; border-radius: 22px;
    background: linear-gradient(135deg, var(--marble), var(--cosmos));
    opacity: .9; z-index: -1; transform: rotate(12deg);
}
@keyframes spinSlow { to { transform: rotate(360deg); } }
.hero-photo {
    width: 100%; border-radius: 20px; aspect-ratio: 4/5;
    object-fit: cover; object-position: top; display: block;
}
.hero-badge {
    position: absolute; bottom: 8%; inset-inline-start: -6%;
    display: flex; align-items: center; gap: .5rem;
    background: var(--surface); border: 1px solid var(--line);
    border-radius: 999px; padding: .55rem 1.1rem;
    font-size: .8rem; font-weight: 700; color: var(--heading);
    box-shadow: var(--shadow-lg);
}
.badge-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--crimson); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(193,18,31,.5);} 50% { box-shadow: 0 0 0 8px rgba(193,18,31,0);} }

.scroll-hint {
    position: absolute; bottom: 1.6rem; inset-inline-start: 50%; transform: translateX(-50%);
    width: 26px; height: 42px; border: 2px solid var(--text-soft); border-radius: 999px;
}
[dir="rtl"] .scroll-hint { transform: translateX(50%); }
.scroll-hint span {
    position: absolute; top: 7px; inset-inline-start: 50%; margin-inline-start: -2px;
    width: 4px; height: 8px; border-radius: 4px; background: var(--accent);
    animation: scrollDot 1.8s infinite;
}
@keyframes scrollDot { 0% { opacity: 1; transform: translateY(0);} 80% { opacity: 0; transform: translateY(14px);} 100% { opacity: 0; } }

/* ---------- الأقسام ---------- */
.section { padding: 6rem 0; }
.section-alt { background: var(--bg-alt); }

.section-head { text-align: center; max-width: 720px; margin: 0 auto 3.2rem; }
.section-tag {
    display: inline-block; font-size: .8rem; font-weight: 800; letter-spacing: .08em;
    text-transform: uppercase; color: var(--marble); margin-bottom: .6rem;
}
.section-title { font-size: clamp(1.7rem, 3.6vw, 2.5rem); color: var(--heading); font-weight: 800; position: relative; display: inline-block; }
.section-title::after {
    content: ""; display: block; width: 64px; height: 4px; border-radius: 4px;
    background: linear-gradient(90deg, var(--crimson), var(--marble));
    margin: .7rem auto 0;
}
.section-sub { color: var(--text-soft); margin-top: 1rem; }

/* ---------- أزرار ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    padding: .85rem 1.9rem; border-radius: 999px; border: 2px solid transparent;
    font-weight: 700; font-size: .95rem; transition: var(--transition);
}
.btn-primary {
    background: linear-gradient(135deg, var(--crimson), var(--gochujang));
    color: #FFF6E6; box-shadow: 0 12px 26px rgba(193, 18, 31, .32);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 18px 34px rgba(193, 18, 31, .42); }
.btn-ghost { border-color: var(--cosmos); color: var(--heading); background: transparent; }
[data-theme="dark"] .btn-ghost { border-color: var(--marble); }
.btn-ghost:hover { background: var(--cosmos); border-color: var(--cosmos); color: var(--cream); transform: translateY(-3px); }
[data-theme="dark"] .btn-ghost:hover { background: var(--marble); border-color: var(--marble); color: #06283A; }
.btn-text { background: none; border: none; color: var(--accent); font-weight: 700; padding: .3rem 0; }
.btn-text:hover { letter-spacing: .03em; }
.btn-block { width: 100%; }

/* ---------- نبذة ---------- */
.about-grid { display: grid; grid-template-columns: 1.4fr .8fr; gap: 2.4rem; align-items: stretch; }
@media (max-width: 820px) { .about-grid { grid-template-columns: 1fr; } }
.about-bio {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 2.4rem; box-shadow: var(--shadow);
    font-size: 1.06rem; color: var(--text);
}
.about-quote {
    border-radius: var(--radius-lg); padding: 2.4rem;
    background: linear-gradient(150deg, var(--cosmos), #065074);
    color: var(--cream); display: flex; align-items: center;
    box-shadow: var(--shadow);
}
.about-quote blockquote { font-size: 1.35rem; font-weight: 700; font-style: italic; line-height: 1.6; }

/* ---------- محاور العمل ---------- */
.focus-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.4rem; }
.focus-card {
    position: relative; background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--radius-lg);
    padding: 2.2rem 1.8rem 1.9rem; overflow: hidden;
    transition: var(--transition); box-shadow: var(--shadow);
}
.focus-card::before {
    content: ""; position: absolute; top: 0; inset-inline-start: 0;
    width: 100%; height: 5px;
    background: linear-gradient(90deg, var(--crimson), var(--marble));
    transform: scaleX(0); transform-origin: inline-start; transition: transform .4s;
}
.focus-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); border-color: var(--accent); }
.focus-card:hover::before { transform: scaleX(1); }
.focus-num {
    display: inline-grid; place-items: center;
    width: 58px; height: 58px; border-radius: 16px;
    font-family: var(--font-en); font-size: 1.5rem; font-weight: 800;
    color: #FFF6E6; line-height: 1;
    background: linear-gradient(135deg, var(--crimson), var(--gochujang));
    box-shadow: 0 8px 18px rgba(193, 18, 31, .35);
}
.focus-card h3 { color: var(--heading); font-size: 1.22rem; margin: .7rem 0 .55rem; }
.focus-card p { color: var(--text-soft); font-size: .96rem; }

/* ---------- المسار (Timeline) ---------- */
.timeline { position: relative; max-width: 860px; margin-inline: auto; }
.timeline::before {
    content: ""; position: absolute; top: 0; bottom: 0;
    inset-inline-start: 27px; width: 3px; border-radius: 3px;
    background: linear-gradient(180deg, var(--crimson), var(--marble), var(--cosmos));
}
.tl-item { position: relative; padding-inline-start: 78px; padding-bottom: 2rem; }
.tl-item:last-child { padding-bottom: 0; }
.tl-dot {
    position: absolute; inset-inline-start: 8px; top: 0;
    width: 42px; height: 42px; border-radius: 50%;
    background: linear-gradient(135deg, var(--crimson), var(--gochujang));
    border: 3px solid var(--surface);
    display: grid; place-items: center;
    box-shadow: 0 6px 16px rgba(193, 18, 31, .4);
}
.tl-dot span { font-family: var(--font-en); font-weight: 800; color: #FFF6E6; }
.tl-card {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 1.4rem 1.7rem;
    box-shadow: var(--shadow); transition: var(--transition);
}
.tl-card:hover { border-color: var(--accent); transform: translateX(6px); }
[dir="rtl"] .tl-card:hover { transform: translateX(-6px); }
.tl-card h3 { color: var(--heading); font-size: 1.12rem; margin-bottom: .3rem; }
.tl-card p { color: var(--text-soft); font-size: .95rem; }

/* ---------- القيادة والأثر ---------- */
.impact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.4rem; }
.impact-card {
    position: relative; border-radius: var(--radius-lg); padding: 2rem 1.8rem;
    background: var(--surface); border: 1px solid var(--line);
    box-shadow: var(--shadow); transition: var(--transition); overflow: hidden;
}
.impact-card::after {
    content: ""; position: absolute; bottom: -40px; inset-inline-end: -40px;
    width: 130px; height: 130px; border-radius: 50%; opacity: .12;
    background: var(--crimson); transition: var(--transition);
}
.impact-card.cat-ecosystem::after { background: var(--marble); }
.impact-card.cat-economic::after { background: var(--cosmos); }
.impact-card.cat-energy::after { background: var(--varden); }
.impact-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.impact-card:hover::after { transform: scale(1.6); opacity: .18; }
.impact-cat {
    display: inline-block; font-size: .74rem; font-weight: 800; letter-spacing: .05em;
    text-transform: uppercase; padding: .28rem .8rem; border-radius: 999px;
    background: var(--accent-soft); color: var(--accent); margin-bottom: .9rem;
}
.impact-card h3 { color: var(--heading); font-size: 1.2rem; margin-bottom: .5rem; }
.impact-card p { color: var(--text-soft); font-size: .95rem; position: relative; z-index: 1; }

/* ---------- رؤى وأفكار ---------- */
.insights-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 1.4rem; }
.insight-card {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 1.8rem;
    box-shadow: var(--shadow); display: flex; flex-direction: column; gap: .7rem;
    transition: var(--transition);
}
.insight-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); border-color: var(--marble); }
.insight-meta { display: flex; justify-content: space-between; align-items: center; gap: .8rem; font-size: .8rem; color: var(--text-soft); }
.insight-cat {
    font-weight: 800; padding: .24rem .75rem; border-radius: 999px;
    background: var(--cosmos); color: var(--cream); font-size: .74rem;
}
[data-theme="dark"] .insight-cat { background: var(--marble); color: #06283A; }
.insight-card h3 { color: var(--heading); font-size: 1.15rem; line-height: 1.45; }
.insight-excerpt { color: var(--text-soft); font-size: .94rem; flex: 1; }
.insight-open { align-self: flex-start; }

/* ---------- تواصل ---------- */
.contact-wrap { max-width: 720px; margin-inline: auto; }
.contact-form {
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 2.4rem; box-shadow: var(--shadow);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
@media (max-width: 620px) { .form-row { grid-template-columns: 1fr; } }
.form-field { margin-bottom: 1.1rem; }
.form-field label { display: block; font-size: .88rem; font-weight: 700; color: var(--heading); margin-bottom: .4rem; }
.form-field input, .form-field textarea {
    width: 100%; padding: .85rem 1rem; border-radius: 12px;
    border: 1.5px solid var(--line); background: var(--bg); color: var(--text);
    font: inherit; transition: border-color .25s, box-shadow .25s;
}
.form-field input:focus, .form-field textarea:focus {
    outline: none; border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
}
.hp-field { position: absolute !important; inset-inline-start: -9999px !important; width: 1px; height: 1px; opacity: 0; }
.form-feedback { margin-top: .9rem; font-weight: 700; font-size: .92rem; min-height: 1.4em; }
.form-feedback.ok { color: #1B8A4C; }
.form-feedback.err { color: var(--crimson); }

/* ---------- تذييل ---------- */
.site-footer {
    background: var(--cosmos); color: #C8D8E2;
    padding: 3rem 0; text-align: center;
}
[data-theme="dark"] .site-footer { background: #010D15; }
.footer-name { font-weight: 800; font-size: 1.15rem; color: var(--cream); }
.footer-tag { font-size: .9rem; margin-top: .3rem; color: var(--marble); }
.footer-copy { font-size: .82rem; margin-top: 1.2rem; opacity: .75; }
.footer-social { display: flex; gap: .6rem; justify-content: center; flex-wrap: wrap; margin-top: 1.4rem; }
.footer-social .social-btn {
    width: 38px; height: 38px; border-radius: 10px;
    background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .14);
    color: #C8D8E2;
}
.footer-social .social-btn:hover { background: var(--crimson); border-color: var(--crimson); color: #fff; transform: translateY(-3px); }

/* ---------- صفحة روابطي ---------- */
.links-group-title {
    font-size: 1.15rem; font-weight: 800; color: var(--text);
    margin: 2.6rem 0 1.2rem; display: flex; align-items: center; gap: .8rem;
}
.links-group-title::before {
    content: ""; width: 26px; height: 4px; border-radius: 4px;
    background: linear-gradient(90deg, var(--crimson), var(--gochujang));
}
.links-grid {
    display: grid; gap: 1rem;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}
.link-card {
    display: flex; align-items: center; gap: 1rem;
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 1rem 1.2rem;
    box-shadow: var(--shadow); transition: var(--transition);
    color: var(--text);
}
.link-card:hover {
    transform: translateY(-4px); box-shadow: var(--shadow-lg);
    border-color: var(--crimson);
}
.link-icon {
    width: 46px; height: 46px; border-radius: 12px; flex-shrink: 0;
    display: grid; place-items: center;
    background: linear-gradient(135deg, var(--crimson), var(--gochujang));
    color: #fff; transition: var(--transition);
}
.link-card:hover .link-icon { transform: scale(1.08) rotate(-4deg); }
.link-card-academic .link-icon { background: linear-gradient(135deg, var(--cosmos), var(--marble)); }
.link-info { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.link-name { font-weight: 800; font-size: .98rem; }
.link-host { font-size: .8rem; color: var(--text-soft); }
.link-arrow {
    margin-inline-start: auto; color: var(--text-soft);
    transition: var(--transition); flex-shrink: 0;
}
.link-card:hover .link-arrow { color: var(--crimson); transform: translate(2px, -2px); }
[dir="rtl"] .link-card:hover .link-arrow { transform: translate(-2px, -2px); }

/* ---------- نافذة المقال ---------- */
.modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 1.2rem; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(2, 16, 24, .65); backdrop-filter: blur(4px); }
.modal-box {
    position: relative; width: min(680px, 100%); max-height: 82vh; overflow: auto;
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 2.4rem; box-shadow: var(--shadow-lg);
    animation: pop .3s cubic-bezier(.2, .9, .3, 1.2);
}
@keyframes pop { from { transform: scale(.92) translateY(16px); opacity: 0; } }
.modal-box h3 { color: var(--heading); font-size: 1.4rem; margin-bottom: 1rem; padding-inline-end: 2rem; }
.modal-body { color: var(--text); white-space: pre-line; }
.modal-close {
    position: absolute; top: 1rem; inset-inline-end: 1rem;
    width: 38px; height: 38px; border-radius: 50%;
    border: 1px solid var(--line); background: var(--bg); color: var(--text);
    font-size: 1.3rem; line-height: 1;
}
.modal-close:hover { background: var(--crimson); color: #fff; border-color: var(--crimson); }

/* ---------- أنيميشن الظهور ---------- */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity .7s ease var(--delay, 0ms), transform .7s cubic-bezier(.2, .7, .3, 1) var(--delay, 0ms); }
.reveal.visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    .blob, .hero-photo-ring, .badge-dot, .scroll-hint span { animation: none; }
}

/* ---------- شريط التمرير ---------- */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg-alt); }
::-webkit-scrollbar-thumb { background: var(--marble); border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: var(--crimson); }

/* ============================================================
   باترن علمي مخصص — جزيئات، ذرات، قطرات ماء (Water • Energy • Nano)
   ============================================================ */
body::before {
    content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260' viewBox='0 0 260 260'%3E%3Cg fill='none' stroke='%23003049' stroke-opacity='.07' stroke-width='1.4'%3E%3Ccircle cx='60' cy='60' r='16'/%3E%3Ccircle cx='60' cy='60' r='30' stroke-dasharray='4 6'/%3E%3Ccircle cx='60' cy='60' r='4' fill='%23003049' fill-opacity='.07' stroke='none'/%3E%3Cpath d='M150 40l26 15v30l-26 15-26-15V55z'/%3E%3Ccircle cx='150' cy='70' r='5'/%3E%3Cpath d='M40 190c14-18 28-18 42 0s28 18 42 0' stroke-opacity='.09'/%3E%3Cpath d='M40 210c14-18 28-18 42 0s28 18 42 0' stroke-opacity='.06'/%3E%3Cpath d='M200 160c0 0-16 20-16 32a16 16 0 0 0 32 0c0-12-16-32-16-32z' stroke-opacity='.08'/%3E%3Cpath d='M90 130l20 20m0-20l-20 20' stroke-opacity='.05'/%3E%3C/g%3E%3C/svg%3E");
    background-size: 260px 260px;
}
[data-theme="dark"] body::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260' viewBox='0 0 260 260'%3E%3Cg fill='none' stroke='%23669BBC' stroke-opacity='.1' stroke-width='1.4'%3E%3Ccircle cx='60' cy='60' r='16'/%3E%3Ccircle cx='60' cy='60' r='30' stroke-dasharray='4 6'/%3E%3Ccircle cx='60' cy='60' r='4' fill='%23669BBC' fill-opacity='.1' stroke='none'/%3E%3Cpath d='M150 40l26 15v30l-26 15-26-15V55z'/%3E%3Ccircle cx='150' cy='70' r='5'/%3E%3Cpath d='M40 190c14-18 28-18 42 0s28 18 42 0'/%3E%3Cpath d='M40 210c14-18 28-18 42 0s28 18 42 0' stroke-opacity='.07'/%3E%3Cpath d='M200 160c0 0-16 20-16 32a16 16 0 0 0 32 0c0-12-16-32-16-32z'/%3E%3Cpath d='M90 130l20 20m0-20l-20 20' stroke-opacity='.06'/%3E%3C/g%3E%3C/svg%3E");
}

/* أيقونات سوشيال أكثر — صف قابل للف */
.hero-social { flex-wrap: wrap; }

/* ---------- تحسينات الجوال ---------- */
@media (max-width: 900px) {
    .container { padding-inline: 1.1rem; }
    .hero { padding-top: 6.5rem; }
    .hero-photo-frame { max-width: 300px; margin-inline: auto; }
    .hero-dots { bottom: 1rem; }
    .section { padding: 4rem 0; }
    .section-title { font-size: 1.9rem; }
    .links-grid { grid-template-columns: 1fr; }
    .link-card { padding: .9rem 1rem; }
    .link-icon { width: 42px; height: 42px; }
    .footer-social { gap: .5rem; }
    .footer-social .social-btn { width: 36px; height: 36px; }
    .contact-form { padding: 1.4rem; }
}
@media (max-width: 480px) {
    .hero-name { font-size: 2rem; }
    .btn { padding: .8rem 1.4rem; font-size: .9rem; }
    .links-group-title { font-size: 1.05rem; }
}

/* بطاقات معلومات التواصل */
.contact-info { display: flex; flex-wrap: wrap; gap: .8rem; justify-content: center; margin-bottom: 2rem; }
.contact-chip {
    display: inline-flex; align-items: center; gap: .55rem;
    background: var(--card); border: 1px solid var(--border); border-radius: 999px;
    padding: .6rem 1.2rem; color: var(--text); font-weight: 600; font-size: .95rem;
    text-decoration: none; transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.contact-chip:hover { transform: translateY(-2px); border-color: var(--accent); box-shadow: 0 8px 20px rgba(0,0,0,.08); }
.contact-chip svg { color: var(--accent); flex-shrink: 0; }
.contact-chip-phones { align-items: center; }
.chip-phones { display: flex; flex-direction: column; gap: .15rem; }
.chip-phones a { color: inherit; text-decoration: none; white-space: nowrap; }
.chip-phones a:hover { color: var(--accent); }
@media (max-width: 600px) { .contact-chip { font-size: .85rem; padding: .5rem .9rem; } }
