*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
  
:root {
  --bg: #0a0a0f;
  --bg2: #111118;
  --bg3: #1a1a24;
  --accent: #7c5cfc;
  --accent2: #a78bfa;
  --accent-glow: rgba(124,92,252,0.15);
  --text: #f0eeff;
  --text2: #9b8ec4;
  --text3: #5a4f7a;
  --border: rgba(124,92,252,0.18);
  --border2: rgba(255,255,255,0.06);
  --card: #13131e;
  --green: #4ade80;
  --pink: #f472b6;
  --sidebar-w: 68px;
  --bottomnav-h: 64px;
  --font: 'Vazirmatn', sans-serif;
}
 
html { scroll-behavior: smooth; }
 
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  direction: rtl;
  overflow-x: hidden;
  display: flex;
}
 
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 2px; }
 
/* ════════════════════════════
   DESKTOP SIDEBAR
════════════════════════════ */
.sidebar {
  position: fixed;
  left: 0; top: 0; bottom: 0;
  width: var(--sidebar-w);
  background: var(--bg2);
  border-right: 1px solid var(--border2);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.4rem 0;
  z-index: 200;
}
 
.sidebar-logo {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; font-weight: 900; color: #fff;
  margin-bottom: 2rem; flex-shrink: 0;
  text-decoration: none;
}
 
.sidebar-nav {
  display: flex; flex-direction: column;
  align-items: center; gap: 0.3rem; flex: 1;
}
 
.sidebar-item {
  position: relative;
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
  color: var(--text3);
  text-decoration: none;
}
.sidebar-item:hover { background: var(--bg3); color: var(--text2); }
.sidebar-item.active { background: var(--accent-glow); color: var(--accent2); }
 
.sidebar-item svg {
  width: 20px; height: 20px;
  stroke: currentColor; stroke-width: 1.8;
  fill: none; stroke-linecap: round; stroke-linejoin: round;
}
 
.sidebar-item::after {
  content: attr(data-label);
  position: absolute;
  left: calc(100% + 10px); top: 50%;
  transform: translateY(-50%);
  background: var(--bg3); border: 1px solid var(--border2);
  color: var(--text); font-size: 0.75rem; font-weight: 600;
  padding: 0.3rem 0.7rem; border-radius: 7px;
  white-space: nowrap; pointer-events: none;
  opacity: 0; transition: opacity 0.15s;
}
.sidebar-item:hover::after { opacity: 1; }
 
.sidebar-divider { width: 28px; height: 1px; background: var(--border2); margin: 0.5rem 0; }
 
.sidebar-bottom {
  display: flex; flex-direction: column;
  align-items: center; gap: 0.3rem;
}
 
/* ════════════════════════════
   MOBILE BOTTOM NAV
════════════════════════════ */
.bottom-nav {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: var(--bottomnav-h);
  background: rgba(17,17,24,0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border2);
  z-index: 200;
  padding: 0 0.5rem;
  align-items: center;
  justify-content: space-around;
}
 
.bn-item {
  display: flex; flex-direction: column;
  align-items: center; gap: 3px;
  padding: 0.4rem 0.8rem;
  border-radius: 12px;
  text-decoration: none;
  color: var(--text3);
  transition: color 0.18s, background 0.18s;
  flex: 1;
}
.bn-item.active { color: var(--accent2); }
.bn-item svg {
  width: 22px; height: 22px;
  stroke: currentColor; stroke-width: 1.8;
  fill: none; stroke-linecap: round; stroke-linejoin: round;
}
.bn-label { font-size: 0.62rem; font-weight: 600; }
 
/* ════════════════════════════
   MAIN
════════════════════════════ */
.main {
  margin-left: var(--sidebar-w);
  flex: 1; min-width: 0;
}
 
/* ════════════════════════════
   HERO — full redesign
════════════════════════════ */
.hero {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 4rem 3rem;
  position: relative;
  overflow: hidden;
  gap: 2rem;
}
 
/* ambient glow */
.hero::before {
  content: '';
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -55%);
  width: 800px; height: 800px;
  background: radial-gradient(circle, rgba(124,92,252,0.07) 0%, transparent 65%);
  pointer-events: none;
}
 
/* ── LEFT PANEL – floating words ── */
.hero-left {
  display: flex; flex-direction: column;
  gap: 1rem; align-items: flex-end;
  padding-left: 1rem;
}
 
.word-float {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.55rem 1.1rem;
  border-radius: 50px;
  border: 1px solid var(--border2);
  background: var(--card);
  font-size: 0.82rem; font-weight: 600;
  color: var(--text2);
  animation: floatY 4s ease-in-out infinite;
  white-space: nowrap;
  cursor: default;
  transition: border-color 0.2s, color 0.2s;
}
.word-float:hover { border-color: var(--accent); color: var(--text); }
.word-float:nth-child(2) { animation-delay: -1.3s; }
.word-float:nth-child(3) { animation-delay: -2.6s; }
.word-float .dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
 
@keyframes floatY {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-8px); }
}
 
/* team link card */
.team-card {
  display: flex; align-items: center; gap: 0.7rem;
  padding: 0.75rem 1.1rem;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--accent-glow);
  text-decoration: none;
  color: var(--accent2);
  font-size: 0.82rem; font-weight: 700;
  transition: background 0.2s, border-color 0.2s;
  margin-top: 0.5rem;
  animation: floatY 4s ease-in-out infinite;
  animation-delay: -0.7s;
}
.team-card:hover { background: rgba(124,92,252,0.25); border-color: var(--accent2); }
.team-card-icon {
  width: 30px; height: 30px;
  border-radius: 8px;
  background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem; flex-shrink: 0;
}
.team-card-text { line-height: 1.3; }
.team-card-label { font-size: 0.68rem; color: var(--text3); font-weight: 500; }
 
/* ── CENTER PANEL ── */
.hero-center {
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
  gap: 0;
  flex-shrink: 0;
}
 
.hero-avatar {
  width: 130px; height: 130px;
  border-radius: 50%;
  background: linear-gradient(145deg, #8b5cf6, #ec4899, #f59e0b);
  padding: 3px; margin-bottom: 1.8rem;
}
.hero-avatar-inner {
  width: 100%; height: 100%;
  border-radius: 50%;
  background: var(--bg2);
  display: flex; align-items: flex-end; justify-content: center;
  overflow: hidden; font-size: 4.5rem; line-height: 1;
  padding-top: 0.4rem;
}
 
.hero-title {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 900; line-height: 1.25; letter-spacing: -0.03em;
  margin-bottom: 1rem;
}
.hero-title .orange { color: #f97316; }
.hero-title .pink   { color: #ec4899; }
 
.hero-desc {
  color: var(--text2); font-size: 0.88rem;
  line-height: 1.9; margin-bottom: 1.8rem;
  max-width: 380px;
}
 
.hero-actions {
  display: flex; gap: 0.9rem; flex-wrap: wrap;
  justify-content: center; margin-bottom: 2.5rem;
}
 
.btn-primary {
  background: var(--text); color: var(--bg);
  padding: 0.7rem 1.6rem; border-radius: 50px;
  text-decoration: none; font-weight: 700;
  font-size: 0.9rem; transition: opacity 0.2s;
}
.btn-primary:hover { opacity: 0.82; }
 
.btn-outline {
  background: var(--accent); color: #fff;
  padding: 0.7rem 1.6rem; border-radius: 50px;
  text-decoration: none; font-size: 0.9rem; font-weight: 700;
  transition: opacity 0.2s;
}
.btn-outline:hover { opacity: 0.85; }
 
.exp-label {
  font-size: 0.7rem; font-weight: 700;
  letter-spacing: 0.12em; color: var(--text3);
  text-transform: uppercase; margin-bottom: 1rem;
}
 
.tech-logos {
  display: flex; gap: 1rem; align-items: center;
  justify-content: center; flex-wrap: wrap;
}
.tech-logo {
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--bg3); border: 1px solid var(--border2);
  display: flex; align-items: center; justify-content: center;
  transition: border-color 0.2s, transform 0.2s; cursor: default;
}
.tech-logo:hover { border-color: var(--accent); transform: translateY(-3px); }
.tech-logo svg { width: 24px; height: 24px; }
 
/* ── RIGHT PANEL – open to work + stats ── */
/* .hero-right {
  display: flex; flex-direction: column;
  gap: 1rem; align-items: flex-start;
  padding-right: 1rem;
} */
 
.open-to-work {
  display: flex; flex-direction: column;
  gap: 0.2rem;
  padding: 1.1rem 1.3rem;
  border-radius: 16px;
  border: 1px solid rgba(74,222,128,0.25);
  background: rgba(74,222,128,0.05);
  animation: floatY 4s ease-in-out infinite;
  animation-delay: -0.4s;
  position: absolute;
  left: 300px;
}
 
.otw-top {
  display: flex; align-items: center; gap: 0.55rem;
  font-size: 0.85rem; font-weight: 700; color: var(--green);
}
.otw-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 0 rgba(74,222,128,0.5);
  animation: ping 2s ease-in-out infinite;
}
@keyframes ping {
  0%   { box-shadow: 0 0 0 0 rgba(74,222,128,0.5); }
  70%  { box-shadow: 0 0 0 8px rgba(74,222,128,0); }
  100% { box-shadow: 0 0 0 0 rgba(74,222,128,0); }
}
.otw-sub { font-size: 0.75rem; color: var(--text3); }
.otw-tags { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-top: 0.3rem; }
.otw-tag {
  font-size: 0.68rem; font-weight: 600;
  padding: 0.2rem 0.65rem; border-radius: 50px;
  background: rgba(74,222,128,0.1);
  color: var(--green);
  border: 1px solid rgba(74,222,128,0.2);
}
 
/* mini stat cards */
.mini-stats { display: flex; flex-direction: column; gap: 0.6rem; }
.mini-stat {
  display: flex; align-items: center; gap: 0.9rem;
  padding: 0.7rem 1rem;
  background: var(--card); border: 1px solid var(--border2);
  border-radius: 12px;
  animation: floatY 4s ease-in-out infinite;
}
.mini-stat:nth-child(1) { animation-delay: -1s; }
.mini-stat:nth-child(2) { animation-delay: -2s; }
.mini-stat:nth-child(3) { animation-delay: -3s; }
.mini-stat-icon {
  width: 34px; height: 34px; border-radius: 9px;
  background: var(--accent-glow); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.95rem; flex-shrink: 0;
}
.mini-stat-num { font-size: 1.1rem; font-weight: 900; color: var(--accent2); line-height: 1; }
.mini-stat-label { font-size: 0.7rem; color: var(--text3); margin-top: 1px; }
 
/* ════════════════════════════
   STATS BAR
════════════════════════════ */
.stats-bar { background: var(--bg2); border-top: 1px solid var(--border2); border-bottom: 1px solid var(--border2); }
.stats-inner {
  max-width: 1000px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 2rem 3rem;
}
.stat { text-align: center; padding: 1rem; border-left: 1px solid var(--border2); }
.stat:last-child { border-left: none; }
.stat-num { font-size: 2.2rem; font-weight: 900; color: var(--accent2); letter-spacing: -0.04em; line-height: 1; }
.stat-label { font-size: 0.82rem; color: var(--text2); margin-top: 0.3rem; }
 
/* ════════════════════════════
   SECTIONS
════════════════════════════ */
section { padding: 5rem 3rem; }
.section-inner { max-width: 1000px; margin: 0 auto; }
 
.section-tag {
  display: inline-block; background: var(--accent-glow);
  border: 1px solid var(--border); color: var(--accent2);
  font-size: 0.75rem; font-weight: 700;
  padding: 0.3rem 0.9rem; border-radius: 50px; margin-bottom: 1rem;
}
.section-title { font-size: clamp(1.7rem, 3vw, 2.4rem); font-weight: 900; letter-spacing: -0.03em; margin-bottom: 0.8rem; line-height: 1.2; }
.section-title span { color: var(--accent2); }
.section-desc { color: var(--text2); font-size: 1rem; max-width: 540px; line-height: 1.8; margin-bottom: 3rem; }
 
/* SKILLS */
.skills-bg { background: var(--bg2); }
.skills-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); gap: 1rem; }
.skill-card { background: var(--card); border: 1px solid var(--border2); border-radius: 12px; padding: 1.2rem 1rem; text-align: center; transition: border-color 0.2s, transform 0.2s; }
.skill-card:hover { border-color: var(--accent); transform: translateY(-3px); }
.skill-icon { font-size: 1.8rem; margin-bottom: 0.5rem; }
.skill-name { font-size: 0.85rem; font-weight: 600; }
.skill-level { font-size: 0.72rem; color: var(--text3); margin-top: 0.2rem; }
.skill-bar { margin-top: 0.6rem; height: 3px; background: var(--bg3); border-radius: 2px; overflow: hidden; }
.skill-bar-fill { height: 100%; background: var(--accent); border-radius: 2px; }
 
/* PROJECTS */
.projects-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; }
.project-card { background: var(--card); border: 1px solid var(--border2); border-radius: 16px; overflow: hidden; transition: border-color 0.2s, transform 0.2s; }
.project-card:hover { border-color: var(--accent); transform: translateY(-4px); }
.project-thumb { height: 170px; display: flex; align-items: center; justify-content: center; font-size: 3rem; position: relative; }
.project-thumb-1 { background: linear-gradient(135deg, #1a1030, #2d1b69); }
.project-thumb-2 { background: linear-gradient(135deg, #0d1f12, #1a3a24); }
.project-thumb-3 { background: linear-gradient(135deg, #1a0d20, #3d1a4a); }
.project-thumb-label { position: absolute; top: 12px; right: 12px; background: var(--accent-glow); border: 1px solid var(--border); color: var(--accent2); font-size: 0.7rem; font-weight: 700; padding: 0.2rem 0.7rem; border-radius: 50px; }
.project-body { padding: 1.3rem; }
.project-title { font-size: 1rem; font-weight: 700; margin-bottom: 0.5rem; }
.project-desc { font-size: 0.83rem; color: var(--text2); line-height: 1.7; margin-bottom: 1rem; }
.project-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1rem; }
.tech-tag { background: var(--bg3); color: var(--text2); font-size: 0.72rem; font-weight: 600; padding: 0.2rem 0.7rem; border-radius: 50px; border: 1px solid var(--border2); }
.project-links { display: flex; gap: 0.8rem; }
.project-link { color: var(--accent2); text-decoration: none; font-size: 0.82rem; font-weight: 600; transition: color 0.2s; }
.project-link:hover { color: var(--text); }
 
/* TIMELINE */
.timeline { position: relative; }
.timeline::before { content: ''; position: absolute; top: 0; bottom: 0; right: 16px; width: 1px; background: var(--border2); }
.timeline-item { padding-right: 50px; padding-bottom: 2.5rem; position: relative; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-dot { position: absolute; right: 8px; top: 6px; width: 17px; height: 17px; border-radius: 50%; background: var(--bg); border: 2px solid var(--accent); z-index: 1; }
.timeline-meta { display: flex; align-items: center; gap: 1rem; margin-bottom: 0.5rem; }
.timeline-date { font-size: 0.78rem; color: var(--text3); font-weight: 600; }
.timeline-badge { font-size: 0.72rem; font-weight: 700; padding: 0.15rem 0.7rem; border-radius: 50px; background: var(--accent-glow); color: var(--accent2); border: 1px solid var(--border); }
.timeline-title { font-size: 1rem; font-weight: 700; margin-bottom: 0.2rem; }
.timeline-company { font-size: 0.85rem; color: var(--accent2); margin-bottom: 0.6rem; font-weight: 600; }
.timeline-desc { font-size: 0.88rem; color: var(--text2); line-height: 1.7; }
 
/* CONTACT */
.contact-bg { background: var(--bg2); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
.contact-info h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 1.5rem; }
.contact-item { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; padding: 0.9rem 1.1rem; background: var(--card); border: 1px solid var(--border2); border-radius: 10px; }
.contact-item-icon { width: 36px; height: 36px; border-radius: 8px; background: var(--accent-glow); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 1rem; flex-shrink: 0; }
.contact-item-label { font-size: 0.72rem; color: var(--text3); }
.contact-item-val { font-size: 0.88rem; font-weight: 600; }
.social-links { display: flex; gap: 0.7rem; margin-top: 1.5rem; }
.social-link { width: 40px; height: 40px; border-radius: 10px; background: var(--card); border: 1px solid var(--border2); display: flex; align-items: center; justify-content: center; font-size: 1.1rem; text-decoration: none; transition: border-color 0.2s, transform 0.2s; }
.social-link:hover { border-color: var(--accent); transform: translateY(-2px); }
.contact-form { display: flex; flex-direction: column; gap: 1rem; }
.form-group label { display: block; font-size: 0.82rem; color: var(--text2); margin-bottom: 0.4rem; font-weight: 500; }
.form-group input, .form-group textarea { width: 100%; background: var(--card); border: 1px solid var(--border2); border-radius: 10px; padding: 0.75rem 1rem; color: var(--text); font-family: var(--font); font-size: 0.9rem; outline: none; transition: border-color 0.2s; direction: rtl; }
.form-group input:focus, .form-group textarea:focus { border-color: var(--accent); }
.form-group textarea { min-height: 120px; resize: vertical; }
.form-group input::placeholder, .form-group textarea::placeholder { color: var(--text3); }
.form-submit { background: var(--accent); color: #fff; border: none; border-radius: 10px; padding: 0.85rem 2rem; font-family: var(--font); font-size: 0.95rem; font-weight: 700; cursor: pointer; transition: opacity 0.2s; }
.form-submit:hover { opacity: 0.85; }
 
footer { background: var(--bg2); border-top: 1px solid var(--border2); padding: 1.8rem 3rem; text-align: center; color: var(--text3); font-size: 0.82rem; }
footer span { color: var(--accent2); }
 
/* ════════════════════════════
   RESPONSIVE
════════════════════════════ */
@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    text-align: center;
    padding: 3rem 1.5rem 5rem;
    gap: 2rem;
  }
  .hero-left, .hero-right { display: none; }
  .hero-center { grid-column: 1; }
}
 
@media (max-width: 768px) {
  .sidebar { display: none; }
  .bottom-nav { display: flex; }
  .main { margin-left: 0; padding-bottom: var(--bottomnav-h); }
  section { padding: 3rem 1.2rem; }
  .stats-inner { grid-template-columns: repeat(2,1fr); padding: 1.5rem 1.2rem; }
  .stat { border-left: none; border-bottom: 1px solid var(--border2); }
  .stat:nth-child(odd) { border-right: 1px solid var(--border2); }
  .projects-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
}