@font-face {
  font-family: Sahel;
  src: url(fonts/webfonts/sahel-font-v1.0.0-alpha14/Sahel.woff);
}

/* ===============================
   تنظیمات پایه
=================================*/
html{
  scroll-behavior: smooth;
}
#services{
  scroll-margin-top: 250px;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Sahel;
}

body {
  background: #f4f6fa;
  color: #222;
  line-height: 1.9;
}

/* کانتینر مرکزی برای نظم */
.container {
  width: 90%;
  max-width: 1200px;
  margin: auto;
}

/* ===============================
   هدر و ناوبری
=================================*/

header {
  background: #0b3d91;
  color: #fff;
  padding: 15px 0;
  position: sticky; /* چسبنده هنگام اسکرول */
  top: 0;
  z-index: 1000;
}

/* ساختار فلکس برای لوگو و منو */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* لوگو */
.logo img {
  height: 75px;
  border-radius: 50px;
}

/* منو دسکتاپ */
.menu {
  display: flex;
  list-style: none;
  gap: 25px;
}

.menu a {
  color: white;
  text-decoration: none;
  font-size: 18px;
  transition: 0.3s;
}

.menu a:hover {
  opacity: 0.7;
}

/* ===============================
   همبرگر موبایل
=================================*/

.hamburger {
  display: none; /* فقط موبایل فعال میشه */
  font-size: 28px;
  cursor: pointer;
}

/* ===============================
   بخش هیرو
=================================*/

.hero {
  background: linear-gradient(135deg, #0b3d91, #1a5fd0);
  color: white;
  padding: 120px 0;
}

.hero-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 50px;
}

/* متن سمت راست */
.hero-text {
  flex: 1;
}

.hero-text h1 {
  font-size: 36px;
  margin-bottom: 20px;
}

.hero-text p {
  margin-bottom: 25px;
  font-size: 20px;
}

/* دکمه */
.btn {
  /* margin-top: 20px; */
  display: inline-block;
  background: white;
  color: #0b3d91;
  padding: 12px 25px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  transition: 0.3s;
}

.btn:hover {
  background: #e5e5e5;
}

/* تصویر هیرو */
.hero-image {
  flex: 1;
}

.hero-image img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

/* ===============================
   سکشن عمومی
=================================*/

section {
  padding: 90px 0;
}

section h2 {
  text-align: center;
  margin-bottom: 50px;
  color: #0b3d91;
}

/* ===============================
   کارت‌های خدمات
=================================*/

.services {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  cursor: pointer;
}

.card {
  background: white;
  /* background: linear-gradient(135deg, #111e3a, #0b3d91); */
  /* color: #d0d7ff; */
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
  transition: 0.6s;
}

.card:hover {
  transform: translateY(-15px);
}

/* ===============================
   نمونه کارها
=================================*/

.portfolio {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 35px;
  cursor: pointer;
}
.portfolio-item {
  display: block;
  text-decoration: none;
  color: inherit;
}

.portfolio-item img {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 15px;
  transition: transform 0.5s ease;
}

.portfolio-item img:hover {
  transform: scale(1.05) translateY(-5px);
}
.portfolio-item h3 {
  text-align: center;
}

.portfolio-btn-wrapper {
  text-align: center;
  margin-top: 50px;
}

.portfolio-main-btn {
  display: inline-block;
  padding: 14px 30px;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 500;
  font-size: 17px;
  background: linear-gradient(135deg, #0b3d91, #1a5fd0);
  color: #fff;
  transition: all 0.5s ease;
}
.portfolio-main-btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

/* ===============================
   فوتر
=================================*/

footer {
  /* background: #111;
  color: #aaa;
  text-align: center;
  padding: 20px;
  font-size: 14px; */
  background: linear-gradient(135deg, #0b3d91, #1a5fd0);
  text-align: center;
  padding: 25px 0;
  font-size: 16px;
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
  color: white;
}

/* ===============================
   انیمیشن ورود هنگام اسکرول
=================================*/

/* حالت اولیه مخفی */
.reveal {
  opacity: 0;
  transform: translateY(60px);
  transition: all 0.8s ease;
}

/* وقتی فعال شود */
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.dark {
  background: #111;
  color: #eee;
}
.dark header {
  background: #000;
}
.dark .card {
  background: #1e1e1e;
}

.dark footer {
  background: #000;
  color: #777;
}

/* ===============================
   ترنزیشن نرم برای تغییر تم
=================================*/

body,
header,
.portfolio-item,
footer,
.hero {
  transition:
    background-color 1.2s cubic-bezier(0.4, 0, 0.2, 1) 0.2s,
    color 1.2s cubic-bezier(0.4, 0, 0.2, 1) 0.2s,
    box-shadow 1.2s cubic-bezier(0.4, 0, 0.2, 1) 0.2s;
}
#themeToggle {
  background: rgba(255, 255, 255, 0.15);
  border: none;
  padding: 6px 12px;
  border-radius: 50px;
  font-size: 18px;
  cursor: pointer;
  backdrop-filter: blur(15px);
  transition: all 0.3s ease;
}
#themeToggle:hover {
  transform: scale(1.05);
}
/* ===============================
   ریسپانسیو موبایل
=================================*/

@media (max-width: 768px) {
  /* منو مخفی میشه */
  .menu {
    position: absolute;
    top: 70px;
    right: 0;
    background: #0b3d91;
    width: 100%;
    flex-direction: column;
    text-align: center;
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.5s ease;
  }

  .menu.show {
    display: flex;
    max-height: 500px;
  }

  .hamburger {
    display: block;
  }

  .hero-content {
    flex-direction: column;
    text-align: center;
  }
}
