/* ===========================
   SetupBridge – Main Stylesheet
   =========================== */

@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@300;400;500;700;800&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --primary:    #2563eb;
  --primary-dk: #1d4ed8;
  --accent:     #0ea5e9;
  --dark:       #0f172a;
  --mid:        #334155;
  --muted:      #64748b;
  --light:      #f1f5f9;
  --border:     #e2e8f0;
  --white:      #ffffff;
  --radius:     14px;
  --shadow:     0 4px 24px rgba(15,23,42,.08);
  --shadow-lg:  0 12px 48px rgba(15,23,42,.14);
  --transition: .25s cubic-bezier(.4,0,.2,1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Tajawal', 'Inter', sans-serif;
  direction: rtl;
  background: var(--white);
  color: var(--dark);
  line-height: 1.7;
  font-size: 16px;
}

a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-dk); }

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

/* ── Container ── */
.container {
  width: 100%;
  max-width: 1100px;
  margin-inline: auto;
  padding-inline: 1.5rem;
}

/* ── Navbar ── */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 1rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--dark);
}

.nav-logo .logo-icon {
  width: 36px; height: 36px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: var(--white);
  font-size: 1.1rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  color: var(--mid);
  font-weight: 500;
  font-size: .95rem;
  padding-block: .25rem;
  border-bottom: 2px solid transparent;
  transition: all var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.nav-cta {
  background: var(--primary);
  color: var(--white) !important;
  border: none !important;
  padding: .5rem 1.25rem;
  border-radius: 50px;
  font-weight: 600 !important;
  transition: background var(--transition), transform var(--transition) !important;
}
.nav-cta:hover { background: var(--primary-dk) !important; transform: translateY(-1px); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: .25rem;
}
.nav-toggle span {
  display: block; width: 24px; height: 2px;
  background: var(--dark); border-radius: 2px;
  transition: all var(--transition);
}

/* ── Hero ── */
.hero {
  padding-block: 6rem 5rem;
  background: linear-gradient(145deg, #f8faff 0%, #eff6ff 60%, #e0f2fe 100%);
  overflow: hidden;
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 800px 600px at 50% 0%, rgba(37,99,235,.07) 0%, transparent 70%);
  pointer-events: none;
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 3rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: rgba(37,99,235,.1);
  color: var(--primary);
  border: 1px solid rgba(37,99,235,.2);
  border-radius: 50px;
  padding: .35rem 1rem;
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.25;
  color: var(--dark);
  margin-bottom: 1.25rem;
}

.hero h1 span {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 1.1rem;
  color: var(--muted);
  margin-bottom: 2rem;
  max-width: 480px;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .75rem 1.75rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: .95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--primary);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--primary-dk);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37,99,235,.35);
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: var(--white);
  transform: translateY(-2px);
}

.hero-visual {
  display: flex;
  justify-content: center;
}

.hero-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 1.75rem;
  width: 100%;
  max-width: 360px;
  border: 1px solid var(--border);
}

.hero-card-header {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.tg-icon {
  width: 42px; height: 42px;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--white);
  font-size: 1.2rem;
}

.hero-card-header h3 { font-size: 1rem; font-weight: 700; }
.hero-card-header p  { font-size: .8rem; color: var(--muted); }

.chat-row {
  display: flex;
  align-items: flex-start;
  gap: .65rem;
  margin-bottom: .85rem;
}

.chat-row.bot { justify-content: flex-start; }
.chat-row.user { justify-content: flex-end; }

.chat-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: .8rem;
  flex-shrink: 0;
}

.chat-avatar.bot-av  { background: #eff6ff; color: var(--primary); }
.chat-avatar.user-av { background: #f0fdf4; color: #16a34a; }

.chat-bubble {
  padding: .6rem 1rem;
  border-radius: 12px;
  font-size: .87rem;
  max-width: 75%;
  line-height: 1.5;
}

.chat-bubble.bot  { background: var(--light); color: var(--dark); border-bottom-right-radius: 4px; }
.chat-bubble.user { background: var(--primary); color: var(--white); border-bottom-left-radius: 4px; }

.upload-bar {
  margin-top: 1rem;
  background: var(--light);
  border-radius: 8px;
  padding: .6rem .9rem;
  display: flex;
  align-items: center;
  gap: .65rem;
  font-size: .82rem;
  color: var(--muted);
}

.upload-bar .dot-anim {
  display: flex; gap: 3px;
}
.upload-bar .dot-anim span {
  width: 5px; height: 5px;
  background: var(--primary);
  border-radius: 50%;
  display: block;
  animation: bounce 1.2s infinite;
}
.upload-bar .dot-anim span:nth-child(2) { animation-delay: .2s; }
.upload-bar .dot-anim span:nth-child(3) { animation-delay: .4s; }

@keyframes bounce {
  0%, 80%, 100% { transform: translateY(0); }
  40%           { transform: translateY(-5px); }
}

/* ── Section ── */
section { padding-block: 5rem; }

.section-label {
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: .75rem;
}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  font-weight: 800;
  color: var(--dark);
  margin-bottom: .75rem;
}

.section-sub {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 560px;
}

.section-head { margin-bottom: 3rem; }

/* ── Features Grid ── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.feature-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: all var(--transition);
}

.feature-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateY(-4px);
}

.feature-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  margin-bottom: 1.25rem;
}

.feature-card h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: .5rem; }
.feature-card p  { color: var(--muted); font-size: .95rem; }

/* ── Stats ── */
.stats-section { background: var(--light); }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  text-align: center;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: .35rem;
}

.stat-label { color: var(--muted); font-size: .95rem; }

/* ── CTA Banner ── */
.cta-banner {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  border-radius: var(--radius);
  padding: 3.5rem 2.5rem;
  text-align: center;
  color: var(--white);
  margin-block: 5rem;
}

.cta-banner h2 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 800; margin-bottom: .75rem; }
.cta-banner p  { opacity: .85; margin-bottom: 2rem; font-size: 1.05rem; }

.btn-white {
  background: var(--white);
  color: var(--primary);
  font-weight: 700;
}
.btn-white:hover { background: var(--light); color: var(--primary-dk); transform: translateY(-2px); }

/* ── Page Header (inner pages) ── */
.page-header {
  padding-block: 4rem 3rem;
  background: linear-gradient(145deg, #f8faff, #eff6ff);
  border-bottom: 1px solid var(--border);
  text-align: center;
}

.page-header h1 { font-size: clamp(1.8rem, 3vw, 2.5rem); font-weight: 800; margin-bottom: .5rem; }
.page-header p  { color: var(--muted); font-size: 1.05rem; }

/* ── Content Page ── */
.content-page { padding-block: 4rem; }

.content-page h2 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--dark);
  margin-top: 2.5rem;
  margin-bottom: .75rem;
  display: flex;
  align-items: center;
  gap: .5rem;
}
.content-page h2::before {
  content: '';
  display: block;
  width: 4px;
  height: 1.2em;
  background: var(--primary);
  border-radius: 2px;
}

.content-page p {
  color: var(--mid);
  margin-bottom: .85rem;
  font-size: .98rem;
}

.content-page ul {
  padding-right: 1.5rem;
  color: var(--mid);
  margin-bottom: .85rem;
  font-size: .98rem;
}

.content-page ul li { margin-bottom: .4rem; }

.info-box {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  margin-block: 1.5rem;
  color: var(--primary-dk);
  font-size: .95rem;
}

/* ── Support Cards ── */
.support-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 2.5rem;
}

.support-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  text-align: center;
  transition: all var(--transition);
}

.support-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateY(-3px);
}

.support-card .s-icon {
  width: 60px; height: 60px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 1.6rem;
  margin: 0 auto 1rem;
}

.support-card h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: .4rem; }
.support-card p  { color: var(--muted); font-size: .9rem; margin-bottom: 1rem; }

/* ── Footer ── */
.footer {
  background: var(--dark);
  color: #94a3b8;
  padding-block: 3.5rem 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 2.5rem;
  margin-bottom: 3rem;
}

.footer-brand .nav-logo { color: var(--white); margin-bottom: .75rem; }
.footer-brand p { font-size: .9rem; line-height: 1.6; max-width: 240px; }

.footer h4 {
  color: var(--white);
  font-size: .95rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.footer ul { list-style: none; }
.footer ul li { margin-bottom: .5rem; }
.footer ul a { color: #94a3b8; font-size: .9rem; transition: color var(--transition); }
.footer ul a:hover { color: var(--white); }

.footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .85rem;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ── Responsive ── */
@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; text-align: center; }
  .hero p { margin-inline: auto; }
  .hero-actions { justify-content: center; }
  .hero-visual { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .nav-links { display: none; flex-direction: column; gap: 1rem; }
  .nav-links.open {
    display: flex;
    position: absolute;
    top: 100%;
    inset-inline: 0;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    padding: 1.5rem;
    text-align: center;
    box-shadow: var(--shadow);
  }
  .nav-toggle { display: flex; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
}
