/* الاستوديو: روح تطبيقات الصور. ملف شخصي، دوائر تصنيف، شبكة مربعات، نافذة منشور.
   الخط: خط النظام مع Noto Sans Arabic، بسيط ومحايد ليترك المساحة للصورة. */
body.ig { background: #FFFFFF; --ig-ink: #0F0F0F; --ig-muted: #737373; --ig-line: #DBDBDB; --ig-soft: #EFEFEF; }
.ig main { font-family: system-ui, -apple-system, "Segoe UI", "Noto Sans Arabic", var(--f-body); color: var(--ig-ink); font-size: 15px; line-height: 1.6; }
.ig-wrap { max-width: 935px; margin-inline: auto; padding: var(--s6) var(--gutter) var(--s8); }

/* رأس الملف */
.ig-profile { display: grid; grid-template-columns: auto 1fr; gap: var(--s4) var(--s6); align-items: center; }
@media (min-width: 740px) { .ig-profile { grid-template-columns: 290px 1fr; } }
.ig-avatar { justify-self: center; width: clamp(86px, 18vw, 160px); aspect-ratio: 1; border-radius: 50%; padding: 4px; border: 3px solid var(--accent); }
.ig-avatar .ph { border-radius: 50%; aspect-ratio: 1; padding: 0; font-size: 0; }
.ig-avatar .ph::before { font-size: 10px; }
.ig-top { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s3); }
.ig-top h1 { font-family: inherit; font-size: 20px; font-weight: 400; direction: ltr; }
.ig-btn { font: 600 14px system-ui, "Noto Sans Arabic", sans-serif; padding: 7px 16px; border-radius: 8px; border: 0; background: var(--ig-soft); color: var(--ig-ink); text-decoration: none; cursor: pointer; transition: background .15s; }
.ig-btn:hover { background: var(--ig-line); }
.ig-btn--blue { background: var(--accent); color: #FFF; }
.ig-btn--blue:hover { background: var(--accent-2); }
.ig-stats { display: flex; gap: var(--s5); list-style: none; padding: 0; margin: var(--s4) 0; }
.ig-stats b { font-weight: 600; }
.ig-bio b { display: block; font-weight: 600; }
.ig-bio p { margin: 0; }
.ig-bio a { color: #00376B; font-weight: 600; text-decoration: none; direction: ltr; display: inline-block; }
@media (max-width: 739px) { .ig-stats, .ig-bio { grid-column: 1 / -1; } .ig-stats { justify-content: space-around; border-block: 1px solid var(--ig-line); padding-block: var(--s2); text-align: center; } .ig-stats li { display: grid; } }

/* دوائر التصنيف */
.ig-highlights { display: flex; gap: var(--s5); overflow-x: auto; padding: var(--s6) 0 var(--s4); scrollbar-width: none; }
.ig-highlights button { flex: none; display: grid; justify-items: center; gap: var(--s2); background: none; border: 0; cursor: pointer; font: 600 12px system-ui, "Noto Sans Arabic", sans-serif; color: var(--ig-ink); }
.ig-highlights .ring { width: 77px; height: 77px; border-radius: 50%; padding: 3px; border: 1px solid var(--ig-line); transition: border-color .15s, transform .2s var(--ease); }
.ig-highlights .ring span { display: block; width: 100%; height: 100%; border-radius: 50%; background: var(--ig-soft); display: grid; place-items: center; font-size: 22px; color: var(--ig-muted); }
.ig-highlights button:hover .ring { transform: scale(1.04); }
.ig-highlights button[aria-pressed="true"] .ring { border: 2px solid var(--accent); }
.ig-highlights button[aria-pressed="true"] { color: var(--accent); }

/* التبويب والشبكة */
.ig-tabs { display: flex; justify-content: center; gap: var(--s7); border-top: 1px solid var(--ig-line); }
.ig-tabs span { display: flex; align-items: center; gap: 6px; padding: 14px 0; margin-top: -1px; border-top: 1px solid var(--ig-ink); font-size: 12px; font-weight: 600; letter-spacing: .05em; }
.ig-tabs svg { width: 12px; height: 12px; }
.ig-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.ig-post { position: relative; aspect-ratio: 1; cursor: pointer; overflow: hidden; border: 0; padding: 0; background: none; }
.ig-post .ph { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; font-size: 11px; }
.ig-post .ov { position: absolute; inset: 0; background: rgba(0,0,0,.45); color: #FFF; display: grid; place-items: center; text-align: center; padding: var(--s2); opacity: 0; transition: opacity .2s; font: 600 14px system-ui, "Noto Sans Arabic", sans-serif; }
.ig-post:hover .ov, .ig-post:focus-visible .ov { opacity: 1; }
.ig-post .multi { position: absolute; top: 8px; left: 8px; width: 18px; height: 18px; color: #FFF; z-index: 1; }

/* نافذة المنشور */
.ig-modal { position: fixed; inset: 0; z-index: 100; background: rgba(0,0,0,.7); display: none; place-items: center; padding: var(--s4); }
.ig-modal.open { display: grid; }
.ig-card { width: min(1000px, 100%); max-height: 90vh; background: #FFF; display: grid; border-radius: 4px; overflow: hidden; }
@media (min-width: 760px) { .ig-card { grid-template-columns: 1.5fr 1fr; } }
.ig-card .media .ph { border-radius: 0; height: 100%; min-height: 320px; aspect-ratio: auto; }
.ig-card .side { display: flex; flex-direction: column; font-family: system-ui, "Noto Sans Arabic", sans-serif; }
.ig-card .who { display: flex; align-items: center; gap: var(--s2); padding: var(--s3); border-bottom: 1px solid var(--ig-line); font-weight: 600; font-size: 14px; }
.ig-card .who i { width: 32px; height: 32px; border-radius: 50%; background: var(--ig-soft); border: 2px solid var(--accent); }
.ig-card .cap { padding: var(--s3); flex: 1; font-size: 14px; }
.ig-card .when { padding: var(--s3); border-top: 1px solid var(--ig-line); font-size: 12px; color: var(--ig-muted); }
.ig-close { position: fixed; top: var(--s3); left: var(--s3); background: none; border: 0; color: #FFF; font-size: 32px; line-height: 1; cursor: pointer; }
.ig-post .ph img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}.ig-post .ph::before{content:none}
