/* =========================
   Base
========================= */
@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@400;500;700&display=swap');

:root{
  --bg: #0b1220;
  --surface: rgba(255,255,255,.06);
  --surface-2: rgba(255,255,255,.10);
  --text: rgba(255,255,255,.92);
  --muted: rgba(255,255,255,.70);
  --line: rgba(255,255,255,.14);

  --brand: #6d5efc;
  --brand2: #21d4fd;

  --primary: #4f7cff;
  --primary2: #6d5efc;

  --radius: 16px;
  --radius2: 22px;
  --shadow: 0 18px 60px rgba(0,0,0,.35);
}

*{ box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body{
  font-family: "Vazirmatn", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: radial-gradient(1200px 600px at 70% -10%, rgba(109,94,252,.30), transparent 60%),
              radial-gradient(900px 500px at 10% 0%, rgba(33,212,253,.22), transparent 55%),
              var(--bg);
  color: var(--text);
}

a{ color: inherit; text-decoration: none; }
.container{ width: min(1100px, 92%); margin: 0 auto; }

.section{ padding: 72px 0; }
.section-alt{ background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,0)); }
.section-head{ margin-bottom: 26px; }
.section-head h2{ margin: 0 0 8px; font-size: clamp(22px, 2.7vw, 30px); }
.section-head p{ margin: 0; color: var(--muted); }

/* =========================
   Topbar
========================= */
.topbar{
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(10px);
  background: rgba(11,18,32,.55);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.topbar-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 14px;
}
.brand{ display:flex; align-items:center; gap: 12px; }
.avatar{
  width: 42px; height: 42px;
  border-radius: 14px;
  display:flex; align-items:center; justify-content:center;
  font-weight: 800;
  background: linear-gradient(135deg, rgba(109,94,252,.35), rgba(33,212,253,.25));
  border: 1px solid rgba(255,255,255,.14);
}
.brand-name{ font-weight: 800; }
.brand-tag{ color: var(--muted); font-size: 13px; margin-top: 2px; }

.nav{
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: center;
}
.nav a{
  color: var(--muted);
  font-weight: 600;
  font-size: 14px;
  padding: 10px 10px;
  border-radius: 12px;
  transition: .2s ease;
}
.nav a:hover{
  color: var(--text);
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.10);
}

.cta{
  background: linear-gradient(135deg, rgba(79,124,255,.95), rgba(109,94,252,.95));
  padding: 10px 14px;
  border-radius: 14px;
  font-weight: 800;
  box-shadow: 0 12px 30px rgba(79,124,255,.22);
  transition: .2s ease;
}
.cta:hover{ transform: translateY(-1px); }

/* =========================
   Hero
========================= */
.hero{ padding: 56px 0 20px; }
.hero-grid{
  display: grid;
  grid-template-columns: 1.3fr .9fr;
  gap: 26px;
  align-items: start;
}
.hero-left h1{
  margin: 0;
  font-size: clamp(28px, 4.2vw, 52px);
  line-height: 1.1;
}
.grad{
  background: linear-gradient(90deg, var(--brand), var(--brand2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.lead{
  margin-top: 14px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.8;
}
.hero-actions{
  display:flex; gap: 12px; flex-wrap: wrap;
  margin-top: 18px;
}
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap: 8px;
  padding: 11px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  color: var(--text);
  font-weight: 800;
  transition: .2s ease;
}
.btn:hover{ transform: translateY(-1px); border-color: rgba(255,255,255,.22); }
.btn.primary{
  border-color: rgba(79,124,255,.45);
  background: linear-gradient(135deg, rgba(79,124,255,.95), rgba(109,94,252,.95));
}
.btn.ghost{ background: rgba(255,255,255,.02); }
.btn.small{ padding: 9px 12px; border-radius: 12px; font-size: 14px; }

.badges{
  margin-top: 18px;
  display:flex; flex-wrap: wrap; gap: 10px;
}
.badge{
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.04);
  color: rgba(255,255,255,.86);
  font-weight: 700;
  font-size: 13px;
}

/* Right profile */
.hero-right{ position: relative; }
.profile-card{
  border-radius: var(--radius2);
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  box-shadow: var(--shadow);
  padding: 18px;
  overflow: hidden;
}
.profile-top{
  display:flex; align-items:center; gap: 12px;
}
.profile-dot{
  width: 12px; height: 12px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--brand2));
  box-shadow: 0 0 0 6px rgba(109,94,252,.18);
}
.profile-title{ font-weight: 900; }
.profile-sub{ color: var(--muted); font-size: 13px; margin-top: 2px; }

.profile-stats{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 18px;
}
.stat{
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.03);
  padding: 12px 10px;
}
.stat-num{ font-weight: 900; font-size: 18px; }
.stat-label{ color: var(--muted); font-size: 12px; margin-top: 4px; }

.profile-line{
  height: 1px;
  background: rgba(255,255,255,.12);
  margin: 16px 0 14px;
}
.quick-links{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
}
.quick-links a{
  padding: 9px 10px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.02);
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
  transition: .2s ease;
}
.quick-links a:hover{
  color: var(--text);
  background: rgba(255,255,255,.06);
}

.glow{
  position:absolute;
  inset: -120px -140px auto auto;
  width: 260px; height: 260px;
  background: radial-gradient(circle, rgba(33,212,253,.25), transparent 60%);
  filter: blur(8px);
  pointer-events: none;
}

/* =========================
   Cards & Layout
========================= */
.two-col{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.card{
  border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  padding: 18px;
}
.card h3{ margin: 0 0 10px; font-size: 18px; }
.card p, .card li{ color: var(--muted); line-height: 1.85; }
.list{
  margin: 0; padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}
.list li{
  padding-right: 18px;
  position: relative;
}
.list li::before{
  content: "✓";
  position:absolute;
  right: 0;
  top: 0;
  color: rgba(33,212,253,.9);
  font-weight: 900;
}

/* =========================
   Skills
========================= */
.skills-grid{
  display:grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}
.skill{
  border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  padding: 16px;
  min-height: 140px;
}
.skill-top{
  display:flex; align-items:center; gap: 10px;
}
.skill-icon{
  width: 28px; height: 28px;
  display:inline-flex; align-items:center; justify-content:center;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.04);
  font-weight: 900;
}
.skill h3{ margin: 0; font-size: 16px; }
.skill p{ margin: 10px 0 0; color: var(--muted); line-height: 1.8; font-size: 14px; }

/* =========================
   Projects
========================= */
.projects-grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.project-card{
  border-radius: var(--radius2);
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  overflow:hidden;
  display:flex;
  flex-direction: column;
}
.project-media{
  position: relative;
  height: 180px;
  background: linear-gradient(135deg, rgba(109,94,252,.20), rgba(33,212,253,.12));
  border-bottom: 1px solid rgba(255,255,255,.10);
}
.project-badge{
  position:absolute;
  top: 14px; right: 14px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(0,0,0,.18);
  color: rgba(255,255,255,.86);
  font-weight: 900;
  font-size: 12px;
}
.project-placeholder{
  height: 100%;
  display:flex; align-items:center; justify-content:center;
  color: rgba(255,255,255,.70);
  font-weight: 900;
  font-size: 14px;
}
.project-body{ padding: 16px; }
.project-body h3{ margin: 0 0 10px; font-size: 20px; }
.project-body p{ margin: 0; color: var(--muted); line-height: 1.85; }
.project-actions{
  margin-top: 14px;
  display:flex; gap: 10px; flex-wrap: wrap;
}

/* =========================
   Contact
========================= */
.contact-grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.contact-item{ margin-top: 14px; }
.contact-label{ color: var(--muted); font-size: 13px; margin-bottom: 6px; }
.contact-value{
  display:inline-block;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.03);
  color: rgba(255,255,255,.90);
  font-weight: 800;
}

.form{ display:grid; gap: 12px; margin-top: 10px; }
.form label{ display:grid; gap: 8px; color: var(--muted); font-weight: 800; font-size: 13px; }
input, textarea{
  width: 100%;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(0,0,0,.18);
  color: var(--text);
  outline: none;
}
textarea{ resize: vertical; min-height: 110px; }
input:focus, textarea:focus{ border-color: rgba(79,124,255,.55); box-shadow: 0 0 0 4px rgba(79,124,255,.15); }
.muted{ color: var(--muted); line-height: 1.8; margin-top: -6px; }
.form-note{ color: rgba(33,212,253,.95); font-weight: 800; min-height: 20px; margin-top: 4px; }

/* Footer */
.footer{
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.10);
  color: var(--muted);
  text-align:center;
  font-weight: 700;
}

/* =========================
   Responsive
========================= */
@media (max-width: 980px){
  .hero-grid{ grid-template-columns: 1fr; }
  .skills-grid{ grid-template-columns: repeat(2, 1fr); }
  .projects-grid{ grid-template-columns: 1fr; }
  .two-col{ grid-template-columns: 1fr; }
  .contact-grid{ grid-template-columns: 1fr; }
  .nav{ display:none; }
}

/* استایل عکس پروفایل */
.profile-image-container {
  margin-bottom: 20px;
  border-radius: var(--radius2);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: var(--shadow);
  height: 320px; /* ارتفاع مناسب برای دسکتاپ */
}

.profile-img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* برای اینکه عکس کشیده نشود */
  transition: transform 0.5s ease;
  filter: grayscale(20%); /* افکت ملایم برای تم مدرن */
}

.profile-image-container:hover .profile-img {
  transform: scale(1.05);
  filter: grayscale(0%);
}

/* تنظیم برای موبایل که عکس بزرگ نباشد */
@media (max-width: 980px) {
  .profile-image-container {
    height: 250px;
  }
}

