/* ===== فونت و استایل پایه ===== */
@font-face {
  font-family: "Vazirmatn";
  src: url("./font/Vazir-Bold.woff") format("woff");
  font-weight: bold;
  font-style: normal;
}

body {
  font-family: 'Vazirmatn', Vazirmatn, Tahoma, Arial, sans-serif !important;
  background: linear-gradient(135deg, #f5f7fa 0%, #e6e0ff 100%);
  color: #4b2067;
  overflow-x: hidden;
}

/* loader */

.loading {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: #fff;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s;
}

.loading.hide {
  opacity: 0;
  pointer-events: none;
}

.ai-matrix-loader {
  width: 300px;
  height: 340px;
  margin: 30px auto;
  position: relative;
  perspective: 800px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
}

.digit {
  color: #00ff88;
  font-family: monospace;
  font-size: 28px;
  text-align: center;
  text-shadow: 0 0 5px #00ff88;
  animation:
    matrix-fall 2s infinite,
    matrix-flicker 0.5s infinite;
  opacity: 0;
}

.digit:nth-child(1) {
  animation-delay: 0.1s;
}
.digit:nth-child(2) {
  animation-delay: 0.3s;
}
.digit:nth-child(3) {
  animation-delay: 0.5s;
}
.digit:nth-child(4) {
  animation-delay: 0.7s;
}
.digit:nth-child(5) {
  animation-delay: 0.9s;
}
.digit:nth-child(6) {
  animation-delay: 1.1s;
}
.digit:nth-child(7) {
  animation-delay: 1.3s;
}
.digit:nth-child(8) {
  animation-delay: 1.5s;
}

.glow {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(
    circle,
    rgba(0, 255, 136, 0.5) 0%,
    transparent 75%
  );
  animation: matrix-pulse 2s infinite;
}

@keyframes matrix-fall {
  0% {
    transform: translateY(-50px) rotateX(90deg);
    opacity: 0;
  }
  20%,
  80% {
    transform: translateY(0) rotateX(0deg);
    opacity: 0.8;
  }
  100% {
    transform: translateY(50px) rotateX(-90deg);
    opacity: 0;
  }
}

@keyframes matrix-flicker {
  0%,
  19%,
  21%,
  100% {
    opacity: 0.8;
  }
  20% {
    opacity: 0.2;
  }
}

@keyframes matrix-pulse {
  0%,
  100% {
    opacity: 0.3;
  }
  50% {
    opacity: 0.7;
  }
}


/* end loader */

/* ===== استایل‌های هدر و نوار ناوبری ===== */
.hero-logo {
  width: 110px;
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px auto;
  font-size: 2.5rem;
  border-radius: 32px;
}
.navbar {
  background: #e6d6ff;
}

#header-tools #datetime {
  font-size: 1.1rem;
  font-weight: bold;
  color: #b388ff;
  margin: 0;
  min-width: 140px;
  justify-content: center;
  padding: 0;
}

#header-tools #datetime i {
  font-size: 1.3rem;
  color: #b388ff;
}

#header-tools input[type="search"] {
  background: transparent;
  border: none;
  box-shadow: none;
  outline: none;
}

#header-tools .btn {
  border-radius: 16px;
  background: #e6d6ff;
  color: #4b2067;
  border: none;
  box-shadow: 0 1px 6px #e6d6ff22;
  transition: 0.2s;
}

#header-tools .btn:hover {
  background: #f8bbd0;
  color: #4b2067;
}

#header-tools #datetime, #header-tools #datetime * {
  color: #000 !important;
  font-family: 'Vazirmatn', Vazirmatn, Tahoma, Arial, sans-serif !important;
  background: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

#datetime {
  font-size: 1.1rem;
  margin-top: 8px;
}

#topbar {
  background: linear-gradient(90deg, #ffe6f7 0%, #e6d6ff 100%);
  border-radius: 0 0 32px 32px;
  box-shadow: 0 4px 24px #e6d6ff55;
  margin-bottom: 12px;
}

#datetime {
  font-size: 1.2rem;
  font-weight: bold;
  color: #b388ff;
  background: #fff6fd;
  border-radius: 16px;
  padding: 4px 18px;
  box-shadow: 0 2px 8px #e6d6ff33;
}

.enter-panel {
  background: #d1b3ff;
  color: #fff;
  border: none;
  transition: 0.2s;
  border-radius: 18px;
  box-shadow: 0 2px 12px #f8bbd055;
  font-size: 1.1rem;
  list-style: none;
  text-decoration: none; /* حذف خط زیر متن */
  display: inline-block; /* برای اعمال padding و margin */
  padding: 10px 25px; /* افزایش اندازه دکمه */
  font-weight: bold; /* متن پررنگ تر */
}

.enter-panel:hover {
  background: #f8bbd0;
  color: #4b2067;
  text-decoration: none; /* حذف خط زیر متن در حالت hover */
}

/* Offcanvas Styles */
@media (min-width: 992px) {
    .offcanvas-lg {
        display: none;
    }
}

.img_offcanvas {
  width: 110px;
}

.offcanvas-body {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.offcanvas_item {
  padding: 10px;
  list-style: none;
  margin-bottom: 10px;
}

.offcanvas_item a {
  color: #000;
  text-decoration: none;
  transition: all 0.3s ease-in-out;
}

.offcanvas_item a:hover {
  color: #d1b3ff;
}

/* ===== استایل‌های صفحه اصلی (Index) ===== */
/*.hero {
  background: linear-gradient(120deg, #e6d6ff 60%, #ffe6f7 100%);
  padding: 80px 0 60px 0;
  text-align: center;
}

.hero-logo {
  width: 110px;
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px auto;
  font-size: 2.5rem;
  border-radius: 32px;
}

.btn-main {
  background: #d1b3ff;
  color: #fff;
  border: none;
  transition: 0.2s;
  border-radius: 18px;
  box-shadow: 0 2px 12px #f8bbd055;
  font-size: 1.1rem;
  list-style: none;
}

.btn-main:hover {
  background: #f8bbd0;
  color: #4b2067;
}*/

.hero {
  padding: 120px 0 100px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
  min-height: 80vh;
  display: flex;
  align-items: center;
}

.hero-bg-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  z-index: 1;
  background-attachment: fixed; /* این خط را اضافه کنید */
}

.hero .container {
  position: relative;
  z-index: 2;
}

.digh1 {
 color: white;
 background-color: #0000002a;
 border-radius: 7px;
 padding: 10px 20px;
 margin-bottom: 20px;
        }
        
.digp {
 color: white;
 background-color: #0000002a;
 border-radius: 7px;
 padding: 10px 20px;
        }


.btn-main {
  background: #d1b3ff;
  color: #fff;
  border: none;
  transition: 0.2s;
  border-radius: 18px;
  box-shadow: 0 2px 12px #f8bbd055;
  font-size: 1.1rem;
  list-style: none;
}

.btn-main:hover {
  background: #f8bbd0;
  color: #4b2067;
}

@media (max-width: 768px) {
  .hero {
    padding: 60px 0 40px 0;
  }
  
  .hero-bg-image {
    background-attachment: scroll !important;
  }
}




.counter {
  font-size: 2.2rem;
  color: #b388ff;
  font-weight: bold;
}

.service-card {
  background: #fff;
  border-radius: 18px;
  padding: 30px 20px;
  margin-bottom: 24px;
  transition: 0.2s;
  border-radius: 32px;
}

.service-card:hover {
  box-shadow: 0 6px 32px #e6d6ff99;
  transform: translateY(-6px) scale(1.03);
}
/* کلاس جدید برای چرخش آیکون هنگام هاور روی div */
.service-card:hover .icon-rotate {
    transform: rotate(360deg);
}

.icon-rotate {
    transition: transform 0.7s ease;
    display: inline-block; /* برای پشتیبانی از transform */
}
.portfolio-card {
    border-radius: 22px;
    box-shadow: 0 6px 32px #b388ff22, 0 1.5px 0 #fff6fd inset;
    overflow: hidden;
    transition: transform 0.25s, box-shadow 0.25s;
    background: #fff;
    position: relative;
    }

.portfolio-card:hover {
    transform: translateY(-8px) scale(1.04) rotate(-1deg);
    box-shadow: 0 12px 48px #b388ff44, 0 1.5px 0 #fff6fd inset;
    }

.portfolio-img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
    transition: filter 0.3s, transform 0.3s;
    filter: brightness(0.92) saturate(1.1);
  }

.portfolio-card:hover .portfolio-img {
    filter: brightness(0.7) blur(1px);
    transform: scale(1.07) rotate(-1deg);
   }

.portfolio-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, #4b2067cc 70%, #fff0 100%);
    opacity: 0;
    transition: opacity 0.3s;
    color: #fff;
    pointer-events: none;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    text-align: center;
    }

.portfolio-card:hover .portfolio-overlay {
    opacity: 1;
    pointer-events: auto;
    }

.portfolio-overlay h5, .portfolio-overlay p {
    text-shadow: 0 2px 8px #4b206799;
      }

.portfolio-overlay .btn {
    margin-top: 8px;
    border-radius: 12px;
    font-size: 0.95rem;
 box-shadow: 0 2px 8px #fff6fd33;
 }
.service-card .icon {
            color: #3498db;
            transition: transform 0.7s ease;
        }
        
        .service-card:hover .icon {
            transform: rotate(360deg);
        }
 /* رنگ هاور متفاوت برای هر کارت نمونه‌کار */
.row .col-md-4:nth-of-type(1) .portfolio-card:hover .portfolio-overlay {
     background: linear-gradient(0deg, #7c3aedcc 70%, #fff0 100%);
    }

.row .col-md-4:nth-of-type(2) .portfolio-card:hover .portfolio-overlay {
    background: linear-gradient(0deg, #f472b6cc 70%, #fff0 100%);
   }

.row .col-md-4:nth-of-type(3) .portfolio-card:hover .portfolio-overlay {
    background: linear-gradient(0deg, #38bdf8cc 70%, #fff0 100%);
  }

.about-card {
  background: #fff;
  border-radius: 28px;
  box-shadow: 0 6px 32px #b388ff22, 0 1.5px 0 #fff6fd inset;
  padding: 2.5rem 2rem 2rem 2rem;
  margin-bottom: 2rem;
  position: relative;
  overflow: hidden;
}

.about-avatar {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, #e6d6ff 60%, #f8bbd0 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.7rem;
  box-shadow: 0 2px 16px #e6d6ff55;
  margin-bottom: 1rem;
}

.about-skill {
  display: inline-flex;
  align-items: center;
  background: #f8e8ff;
  color: #7c3aed;
  border-radius: 16px;
  padding: 2px 10px 2px 8px;
  margin: 0 2px;
  font-size: 1rem;
  font-weight: 500;
  box-shadow: 0 1px 4px #e6d6ff22;
}

.about-skill i {
  margin-left: 4px;
  font-size: 1.1em;
}

.about-stat {
  background: #f5f7fa;
  border-radius: 18px;
  box-shadow: 0 2px 12px #e6d6ff33;
  padding: 1.1rem 0.5rem 0.7rem 0.5rem;
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}

.about-stat:hover {
  transform: scale(1.07) rotate(-2deg);
  box-shadow: 0 6px 24px #b388ff44;
}

.about-stat-icon {
  font-size: 2rem;
  color: #b388ff;
  margin-bottom: 0.3rem;
}

.about-stat-num {
  font-size: 1.3rem;
  font-weight: bold;
  color: #4b2067;
}

.about-stat-label {
  font-size: 0.95rem;
  color: #7c3aed;
  margin-top: 0.2rem;
}

#fontSelector {
  min-width: 120px;
  font-size: 0.95rem;
}

/* ===== استایل‌های فوتر ===== */

.footer-waves {
  position: relative;
  width: 100vw !important;
  height: 30%;
  margin-bottom: -38px;
  min-height: 70px;
  max-height: 100px;
  left: 50%;
  right: 50%;
  margin-left: -50vw !important;
  margin-right: -50vw !important;
}

.footer-wave-svg {
  position: relative;
  width: 100vw !important;
  height: 30%;
  margin-bottom: -38px;
  min-height: 70px;
  max-height: 100px;
  left: 50%;
  right: 50%;
  margin-left: -50vw !important;
  margin-right: -50vw !important;
}

.footer-wave-parallax>use {
  animation: footer-wave-animation 25s cubic-bezier(0.55, 0.5, 0.45, 0.5) infinite;
}

.footer-wave-parallax>use:nth-child(1) {
  animation-delay: -2s;
  animation-duration: 7s;
}

.footer-wave-parallax>use:nth-child(2) {
  animation-delay: -3s;
  animation-duration: 10s;
}

.footer-wave-parallax>use:nth-child(3) {
  animation-delay: -4s;
  animation-duration: 13s;
}

.footer-wave-parallax>use:nth-child(4) {
  animation-delay: -5s;
  animation-duration: 20s;
}
.note-style{
    text-align:center;
}
@keyframes footer-wave-animation {
  0% {
    transform: translate3d(-90px, 0, 0);
  }

  100% {
    transform: translate3d(85px, 0, 0);
  }
}

.p1 {
  text-align: center;
}

/* ===== استایل‌های نوار کناری (Sidebar) ===== */
/* --- Start Sidebar Styles --- */

@media( max-width: 1010px ) {
  .sidebar {
    visibility: hidden;
  }
}

.sidebar {
   transform: translate3d(0,-50%,0);

    right: 0;
    align-items: flex-start;

    position: fixed;
    top: 50%;
    z-index: 390;
    display: flex;
    flex-direction: column;
    transition: all 0.5s cubic-bezier(.19,1,.22,1) 1s;
    user-select: none;
}

.a_style {
    text-decoration: none;
    color: white;
}

/* ............. */

#instagram {
    height: 40px;
    width: 40px;
    background-color: #ffffff;
    color: #d1b3ff;
    border-top: 2px solid #d1b3ff;
    border-left: 2px solid #d1b3ff;
    border-bottom: 1px solid #d1b3ff;
    border-top-left-radius: 10px;
    font-weight: bold;
}

#instagram:hover {
    width: 118px;
    border-bottom-left-radius: 10px;
}

#linkedin {
    height: 40px;
    width: 40px;
    background-color: #ffffff;
    color: #d1b3ff;
    border-bottom: 1px solid #d1b3ff;
    border-left: 2px solid #d1b3ff;
    border-top: 1px solid #d1b3ff;
    font-weight: bold;
}

#linkedin:hover {
    width: 110px;
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
}

#rubika {
    height: 40px;
    width: 40px;
    background-color: #ffffff;
    color: #d1b3ff;
    border-left: 2px solid #d1b3ff;
    border-bottom: 1px solid #d1b3ff;
    border-top: 1px solid #d1b3ff;
    border-bottom-left-radius: 10px;
    font-weight: bold;
}

#rubika:hover {
    width: 99px;
    border-top-left-radius: 10px;
}

/* ............ */

.sidebar_item {
    transition: width 0.09s linear 0s;
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    overflow: hidden;
    margin: 0;
    min-width: 40px;
    width: auto;
    height: 40px;
}

#instagram_img {
    margin-right: 10px;
    margin-left: 10px;
    font-size: 18px;
}

#linkedin_img {
    margin-right: 10px;
    margin-left: 10px;
    font-size: 18px;
}

#rubika_img {
    margin-right: 3px;
    margin-left: 10px;
    height: 30px;
}

/* ............ */

#instagram_text {
    visibility: hidden;
}

#instagram:hover #instagram_text {
    visibility: visible;
}

#linkedin_text {
    visibility: hidden;
}

#linkedin:hover #linkedin_text {
    visibility: visible;
}


#rubika_text {
    visibility: hidden;
}

#rubika:hover #rubika_text {
    visibility: visible;
}

/* --- End Sidebar Styles --- */