@import url('https://fonts.googleapis.com/css2?family=Lalezar&display=swap');

body {
  margin: 0;
  padding: 0;
  font-family: 'Lalezar', cursive;
  color: #4e2e1a;
  line-height: 2;
  text-align: center;
}








header {
    position: relative;
    background: #3c2f2f;
    color: #f5e6cc;
    padding: 0.6rem 1rem; /* کاهش ارتفاع */
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 3px solid #8a5522;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* سه بخش چپ، وسط، راست */
.header-left,
.header-center,
.header-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* موقعیت‌های دقیق */
.header-left {
    justify-content: flex-start;
}

.header-right {
    justify-content: flex-end;
}

/* لوگو */
.logo {
    height: 80px;
    width: 100px;
    object-fit: contain;
    align-items: center;
}

/* عنوان */
.header-right h1 {
    font-size: 1.2rem;
    margin: 0;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.home-icon i {
    font-size: 20px; /* یا هر مقدار دلخواه مثلاً 24px */
    color: #f5e6cc;
    transition: color 0.3s;
}

.home-icon i:hover {
    color: #e6b800;
}

/* رسپانسیو برای موبایل */
@media (max-width: 768px) {
    header {
        padding: 0.3rem 0.5rem;
    }
    .logo {
    width: 60px; /* اندازه کوچکتر در موبایل */
    height: 50px;
    padding: 0;
    margin: 0;
    }

    .header-right h1 {
        font-size: 1rem;
    }

    .header-left a {
        font-size: 1.2rem;
    }
}









.container {
  background: rgba(255, 245, 230, 0.85); /* زمینه کرمی نیمه‌شفاف */
  padding: 40px 20px;
  min-height: 100vh;
  box-sizing: border-box;
}

.intro h1 {
  font-size: 36px;
  margin-bottom: 20px;
  color: #5c2d15;
}

.intro p {
  max-width: 800px;
  margin: 0 auto;
  font-size: 20px;
  color: #3d2b1f;
  animation: fadeIn 3s ease-in-out;
}

.button-container {
  margin-top: 60px;
  display: flex;
  justify-content: center;
  animation: slideUp 2s ease-out;
}

button {
  padding: 15px 30px;
  font-size: 22px;
  font-family: 'Lalezar', cursive;
  background: linear-gradient(135deg, #d2b48c, #8b5e3c);
  color: #fff;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.3s ease, background 0.3s ease;
  box-shadow: 0 8px 16px rgba(0,0,0,0.3);
}

button:hover {
  transform: scale(1.08);
  background: linear-gradient(135deg, #c49b75, #6e4322);
}

/* انیمیشن‌ها */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(100px); }
  to { opacity: 1; transform: translateY(0); }
}


.container {
  position: relative;
  z-index: 1;
}


/* حالت شب */
body.dark {
  background-color: #1e1a16; /* پس‌زمینه تیره شاعرانه */
  color: #fdfdfd; /* رنگ متن سفید ملایم */
}

/* المان‌های داخلی */
body.dark .container,
body.dark .result,
body.dark .intro,
body.dark .interpretation,
body.dark .poem-title {
  background: transparent;
  color: #fff;
}

/* دکمه‌ها در حالت دارک */
body.dark .button,
body.dark #modeToggle {
  background-color: #5a3e2b;
  color: #ffffff;
  border: 1px solid #a8846a;
}

/* لینک‌ها و متن‌های قابل کلیک */
body.dark a {
  color: #ffd9a0;
}

/* افکت ملایم */
body.dark .button:hover,
body.dark #modeToggle:hover {
  background-color: #704f38;
}
#modeToggle {
  position: fixed;
  top: 15px;
  left: 15px;
  padding: 6px 14px;
  font-size: 14px;
  background-color: #8b5e3c;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  z-index: 999;
  transition: all 0.3s ease;
}
#modeToggle:hover {
  background-color: #a16c45;
}



body.dark p,
body.dark h1,
body.dark h2,
body.dark span,
body.dark div {
  color: #ffffff;
}









/* ریست حاشیه‌ها و پدینگ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}


/* استایل محتوای اصلی */
.content {
  padding: 40px;
  text-align: center;
  min-height: 80vh; /* برای اطمینان از اینکه فوتر در پایین باشد */
}

/* استایل فوتر */
.footer {
  background-color: #2d2d2d; /* خاکستری تیره برای کنتراست */
  color: #ffffff;
  padding: 40px 20px;
  text-align: center;
  width: 100%;
}

/* محتوای فوتر */
.footer-content {
  max-width: 1300px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* دکمه درباره ما */
.about-button .btn {
  display: inline-block;
  padding: 12px 24px;
  background-color: #05396d; /* آبی جذاب */
  color: #ffffff;
  text-decoration: none;
  border-radius: 25px;
  font-size: 20px;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.about-button .btn:hover {
  background-color: #1678d6; /* تیره‌تر هنگام هاور */
  transform: translateY(-2px);
}

/* آیکون‌های شبکه‌های اجتماعی */
.social-icons {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.social-icons a {
  color: #f7f2f2;
  font-size: 28px;
  transition: color 0.3s ease, transform 0.2s ease;
}

.social-icons a:hover {
  color: #4134ee; /* آبی هنگام هاور */
  transform: scale(1.1);
}

/* استایل ایمیل */
.email p {
  font-size: 20px;
}

.email a {
  color: #3960bb;
  text-decoration: none;
}

.email a:hover {
  text-decoration: underline;
}

/* استایل کپی‌رایت */
.copyright p {
  font-size: 20px;
  color: #ffffff;
  margin-top: 10px;
}

/* برای نمایش بهتر در موبایل */
@media (max-width: 768px) {
  .footer {
      padding: 30px 15px;
  }

  .social-icons a {
      font-size: 24px;
      gap: 15px;
  }

  .about-button .btn {
      padding: 10px 20px;
      font-size: 17px;
  }

  .email p {
      font-size: 17px;
  }

  .copyright p {
      font-size: 17px;
  }
}


#scrollToTopBtn {
    display: none; 
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #04359e;
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    font-size: 24px;
    line-height: 50px;
    text-align: center;
    transition: all 0.3s ease;
    animation:pulse 3s infinite;
  }
  