/* منصة مشروع العُمر — نسخة ويب بعرض كامل الشاشة */
:root {
  --ivory: #faf8f3;
  --surface: #ffffff;
  --emerald: #0e7c66;
  --emerald-dark: #0b5e4e;
  --sage-soft: #e4efea;
  --clay: #c97b5a;
  --ink: #1c1b19;
  --ink-soft: #6b6a66;
  --ink-muted: #9c9a94;
  --line: #ede8df;
  --radius-card: 22px;
  --radius-inner: 16px;
  --radius-pill: 999px;
  --sidebar-w: 272px;
  --shadow-soft: 0 12px 40px rgba(14, 124, 102, 0.08);
  --font: 'IBM Plex Sans Arabic', system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  height: 100%;
  font-family: var(--font);
  background: var(--ivory);
  color: var(--ink);
}

#app-shell,
.app-shell {
  min-height: 100vh;
  width: 100%;
}

/* ─── تخطيط كامل الشاشة: شريط جانبي + محتوى ─── */
.app-shell.has-nav {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
}

@media (min-width: 960px) {
  .app-shell.has-nav {
    grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
  }
}

.main-panel {
  min-height: 100vh;
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--ivory);
}

.app-main {
  flex: 1;
  width: 100%;
  overflow-x: hidden;
}

.page-inner {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 20px 24px 120px;
}

@media (min-width: 1200px) {
  .page-inner {
    padding: 28px 40px 48px;
  }
}

/* ─── تنقل جانبي (ديسكتوب) ─── */
.sidebar {
  display: none;
  background: var(--surface);
  border-left: 1px solid var(--line);
  padding: 28px 18px;
  flex-direction: column;
  gap: 8px;
  position: sticky;
  top: 0;
  height: 100vh;
}

@media (min-width: 960px) {
  .sidebar {
    display: flex;
  }
}

.sidebar::before {
  content: 'منصة مشروع العُمر';
  display: block;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--emerald);
  margin-bottom: 24px;
  padding: 0 12px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius-inner);
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 700;
  transition: background 0.2s, color 0.2s;
}

.nav-item:hover,
.nav-item.active {
  background: var(--sage-soft);
  color: var(--emerald);
}

.nav-icon {
  font-size: 1.25rem;
  width: 28px;
  text-align: center;
}

/* ─── تنقل سفلي (جوال) ─── */
.bottom-nav {
  display: flex;
  justify-content: space-around;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: var(--surface);
  border-top: 1px solid var(--line);
  position: sticky;
  bottom: 0;
  z-index: 20;
}

@media (min-width: 960px) {
  .bottom-nav {
    display: none;
  }
}

.bottom-nav .nav-item {
  flex-direction: column;
  gap: 4px;
  padding: 8px 12px;
  font-size: 0.72rem;
}

/* صفحة الدخول → css/login.css */

.field {
  display: block;
  margin-bottom: 16px;
}

.field span {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-soft);
  margin-bottom: 6px;
}

.field input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-inner);
  font: inherit;
  background: var(--ivory);
}

.form-error {
  color: #cb5a5a;
  font-size: 0.85rem;
  margin: 0 0 12px;
}

/* ─── أزرار ─── */
.btn {
  border: none;
  border-radius: var(--radius-pill);
  padding: 14px 22px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.15s, opacity 0.15s;
}

.btn:active {
  transform: scale(0.98);
}

.btn-block {
  width: 100%;
}

.btn-primary {
  background: linear-gradient(135deg, var(--emerald), var(--emerald-dark));
  color: #fff;
}

.btn-white {
  background: #fff;
  color: var(--emerald);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--line);
  color: var(--ink);
}

.icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  font-size: 1.1rem;
}

/* ─── رأس الصفحة ─── */
.page-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

.page-kicker {
  margin: 0 0 4px;
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 0.9rem;
}

.page-title {
  margin: 0;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 900;
}

.page-sub {
  margin: 6px 0 0;
  color: var(--ink-soft);
}

/* ─── بطاقة المستشار — عرض كامل ─── */
.hero-card {
  position: relative;
  border-radius: var(--radius-card);
  overflow: hidden;
  margin-bottom: 28px;
  box-shadow: 0 20px 50px rgba(14, 124, 102, 0.22);
}

.hero-card__bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--emerald) 0%, var(--emerald-dark) 100%);
}

.hero-card__content {
  position: relative;
  padding: clamp(22px, 4vw, 36px);
}

.hero-card__head {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

@media (min-width: 768px) {
  .hero-card__head {
    align-items: center;
  }
}

.hero-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.hero-avatar {
  width: clamp(72px, 10vw, 96px);
  height: clamp(72px, 10vw, 96px);
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(255, 255, 255, 0.5);
}

.hero-verified {
  position: absolute;
  bottom: 0;
  left: 0;
  background: #cba35a;
  color: #fff;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  border: 2px solid var(--emerald-dark);
}

.hero-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.hero-card__titles h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 900;
}

.hero-sub {
  margin: 6px 0 0;
  color: rgba(255, 255, 255, 0.88);
}

.hero-tagline {
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.7;
  max-width: 720px;
}

.hero-highlights {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin: 20px 0;
  padding: 14px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-inner);
}

.hero-highlight {
  text-align: center;
  color: #fff;
}

.hero-highlight strong {
  display: block;
  font-size: 1.25rem;
}

.hero-highlight span {
  font-size: 0.8rem;
  opacity: 0.9;
}

/* ─── أقسام ─── */
.section-block {
  margin-bottom: 32px;
}

.section-title {
  margin: 0 0 16px;
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--emerald);
}

.features-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.feature-pill {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-inner);
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-inner);
  padding: 20px;
  text-align: center;
  box-shadow: var(--shadow-soft);
}

.stat-value {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--emerald);
}

.stat-label {
  margin-top: 6px;
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 24px;
}

.body-text {
  line-height: 1.85;
  color: var(--ink-soft);
  margin: 0;
}

.chips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}

.chip-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-inner);
  padding: 18px;
}

.chip-card p {
  margin: 8px 0 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.timeline {
  display: grid;
  gap: 16px;
}

.timeline-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.timeline-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--emerald);
  margin-top: 6px;
  flex-shrink: 0;
}

.certs-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cert-card {
  background: linear-gradient(135deg, #f6e9e2, #fff);
  border: 1px solid var(--line);
  padding: 12px 18px;
  border-radius: var(--radius-pill);
  font-weight: 700;
  color: var(--clay);
}

/* مواعيد / متجر */
.banner-plan {
  background: var(--sage-soft);
  border-radius: var(--radius-inner);
  padding: 16px 18px;
  margin-bottom: 24px;
  font-weight: 600;
  color: var(--emerald-dark);
}

.meetings-list,
.products-grid {
  display: grid;
  gap: 12px;
}

@media (min-width: 640px) {
  .products-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }
}

.meeting-card,
.product-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-inner);
  padding: 16px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.product-card {
  flex-direction: column;
  align-items: stretch;
  padding: 0;
  overflow: hidden;
}

.product-cover {
  height: 160px;
  background: var(--sage-soft) center/cover no-repeat;
  display: grid;
  place-items: center;
  font-size: 2.5rem;
}

.product-body {
  padding: 14px 16px;
}

.product-body h3 {
  margin: 0 0 6px;
  font-size: 1rem;
}

.badge {
  background: var(--sage-soft);
  color: var(--emerald);
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 800;
}

.muted {
  color: var(--ink-muted);
  font-size: 0.88rem;
}

.store-note {
  margin-top: 20px;
  text-align: center;
}

.page-loading,
.empty-state {
  padding: 48px 24px;
  text-align: center;
  color: var(--ink-soft);
}

.profile-card p {
  margin: 0 0 10px;
}
