@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@400;600&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Vazirmatn", sans-serif;
}

body {
  margin: 0;
  font-family: "Vazir", sans-serif;
  background-color: #f4f4f4;
  color: #333;
  direction: rtl;
}

/* ===========================
   نوار بالایی (ساعت و تلفن)
=========================== */
.topbar {
  background-color: #333;
  color: #f0f0f0;
  font-size: 14px;
  padding: 8px 0;
}

.topbar .container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
  flex-wrap: wrap;
}

.topbar a {
  color: #ffd166;
  font-weight: bold;
}

.topbar a:hover {
  color: #fff;
}

/* Header */
header {
    background: #444;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 30px;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo {
    font-size: 1.2rem;
    font-weight: 600;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

nav ul li a {
    color: white;
    text-decoration: none;
    transition: color 0.3s;
}

nav ul li a:hover {
    color: #ffc107;
}

.menu-toggle {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
}

/* Hero Section */
.hero {
    background: url('../images/banner.jpg') center/cover no-repeat;
    text-align: center;
    color: white;
    padding: 100px 20px;
    background-color: #555;
}

.hero h1 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.hero p {
    font-size: 1.1rem;
}
/* About Section */
.about {
    background: #eaeaea;
    padding: 70px 20px;
    text-align: center;
}

.about h2 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 40px;
}

.about-content {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 40px;
    max-width: 1100px;
    margin: 0 auto;
}

.about-text {
    flex: 1 1 400px;
    text-align: justify;
    line-height: 2;
    color: #444;
}

.about-text p {
    margin-bottom: 15px;
}

.about-image {
    flex: 1 1 350px;
}

.about-image img {
    width: 100%;
    max-width: 400px;
    border-radius: 15px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
}

/* برای موبایل */
@media (max-width: 768px) {
    .about-content {
        flex-direction: column;
        text-align: center;
    }
    .about-text {
        text-align: center;
    }
}


/* Services */
/* Services Section */
.services {
    background-color: #f0f0f0;
    padding: 80px 20px;
    text-align: center;
}

.services h2 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 50px;
}

.services-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.service-box {
    background-color: #fff;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.service-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

.service-box img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 15px;
}

.service-box h3 {
    font-size: 1.3rem;
    color: #222;
    margin-bottom: 10px;
}

.service-box p {
    color: #555;
    line-height: 1.8;
    font-size: 0.95rem;
    text-align: justify;
}

/* Responsive */
@media (max-width: 768px) {
    .services-container {
        flex-direction: column;
        align-items: center;
    }
}



/* Gallery Section */
.gallery {
    text-align: center;
    padding: 60px 20px;
    background: #f4f4f4;
}

.gallery h2 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 30px;
}

.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 15px;
    justify-items: center;
    max-width: 1100px;
    margin: 0 auto;
}

.gallery-container img {
    width: 100%;
    max-width: 250px;
    height: 170px;
    object-fit: cover;
    border-radius: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-container img:hover {
    transform: scale(1.05);
    box-shadow: 0 3px 10px rgba(0,0,0,0.3);
}


/* ===========================
   فوتر
=========================== */
.footer {
  background-color: #222;
  color: #ccc;
  padding: 50px 20px 10px;
}

.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.footer h3, .footer h4 {
  color: #fff;
}

.footer a {
  color: #ffd166;
}

.footer a:hover {
  color: #fff;
}

.social-links {
  display: flex;
  gap: 12px;
}

.social-links img {
  width: 28px;
  height: 28px;
  filter: brightness(0.9);
  transition: filter 0.3s ease;
}

.social-links img:hover {
  filter: brightness(1.3);
}

.footer-bottom {
  text-align: center;
  border-top: 1px solid #444;
  margin-top: 30px;
  padding-top: 15px;
  font-size: 14px;
  color: #999;
}


/* Back to Top Button */
#backToTop {
    position: fixed;
    bottom: 30px;
    left: 30px;
    background: #444;
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    display: none;
}

#backToTop:hover {
    background: #ffc107;
}

/* Responsive Menu */
@media (max-width: 768px) {
    nav ul {
        display: none;
        flex-direction: column;
        background: #444;
        position: absolute;
        top: 60px;
        right: 0;
        width: 100%;
        text-align: center;
        padding: 10px 0;
    }

    nav ul.active {
        display: flex;
    }

    .menu-toggle {
        display: block;
    }

    .service-container, .gallery-container {
        flex-direction: column;
    }

    .gallery img {
        width: 90%;
    }
}
/* Gallery Page */
.gallery-page {
    text-align: center;
    padding: 60px 20px;
    background: #f4f4f4;
}

.gallery-page h1 {
    margin-bottom: 30px;
    color: #444;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    justify-items: center;
}

.gallery-grid img {
    width: 100%;
    max-width: 350px;
    height: 230px;
    object-fit: cover;
    border-radius: 10px;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.gallery-grid img:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* Active Menu */
nav ul li a.active {
    color: #ffc107;
}
/* Lightbox Styles */
.lightbox {
    display: none;
    position: fixed;
    z-index: 2000;
    padding-top: 50px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.9);
    text-align: center;
}

.lightbox-img {
    margin: auto;
    display: block;
    max-width: 80%;
    max-height: 80%;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(255,255,255,0.2);
}

.close {
    position: absolute;
    top: 30px;
    left: 40px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
}

.prev, .next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 40px;
    font-weight: bold;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    transition: 0.3s;
}

.prev:hover, .next:hover {
    color: #ffc107;
}

.prev { right: 60px; }
.next { left: 60px; }

@media (max-width: 768px) {
    .lightbox-img {
        max-width: 95%;
        max-height: 70%;
    }
}
/* Map Section */
.map-section {
    background-color: #f5f5f5;
    padding: 60px 20px;
    text-align: center;
}

.map-section h2 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 30px;
}

.map-container {
    max-width: 1000px;
    margin: 0 auto;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

/* Contact Form Section */
.contact-form-section {
    background-color: #ffffff;
    padding: 70px 20px;
    text-align: center;
}

.contact-form-section h2 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 20px;
}

.contact-form-section p {
    color: #666;
    margin-bottom: 40px;
}

.contact-form {
    max-width: 600px;
    margin: 0 auto;
    text-align: right;
    direction: rtl;
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: bold;
}

input, textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #bbb;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    box-sizing: border-box;
}

input:focus, textarea:focus {
    border-color: #555;
    outline: none;
}

.btn-submit {
    background-color: #555;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s;
}

.btn-submit:hover {
    background-color: #333;
}

.form-status {
    margin-top: 20px;
    font-weight: bold;
}
/* Contact Section (Two Columns) */
.contact-section {
    background: #f8f8f8;
    padding: 80px 20px;
    text-align: center;
}

.contact-section h2 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 50px;
}

.contact-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 40px;
    max-width: 1100px;
    margin: 0 auto;
    text-align: right;
    direction: rtl;
}

.contact-info, .contact-form-box {
    flex: 1 1 450px;
    background: #fff;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.contact-info h3, .contact-form-box h3 {
    color: #333;
    margin-bottom: 20px;
}

.contact-info p {
    margin-bottom: 12px;
    color: #555;
    line-height: 1.8;
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 6px;
    color: #333;
    font-weight: bold;
}

input, textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #bbb;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    box-sizing: border-box;
}

input:focus, textarea:focus {
    border-color: #666;
    outline: none;
}

.btn-submit {
    background-color: #555;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s;
}

.btn-submit:hover {
    background-color: #333;
}

.form-status {
    margin-top: 15px;
    font-weight: bold;
}

/* واکنش‌گرا برای موبایل */
@media (max-width: 768px) {
    .contact-container {
        flex-direction: column;
        gap: 20px;
    }
}
/* نوار بالای سایت */
.topbar {
    background-color: #2f2f2f; /* خاکستری تیره صنعتی */
    color: #f1f1f1;
    font-size: 15px;
    padding: 8px 0;
    direction: rtl;
}

.topbar .container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    flex-wrap: wrap;
}

.topbar span {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* واکنش‌گرا برای موبایل */
@media (max-width: 600px) {
    .topbar .container {
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }
}
.topbar a {
    color: #f0f0f0;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.topbar a:hover {
    color: #ffd166; /* زرد روشن هنگام هاور */
}
/* ===== فوتر ===== */
.footer {
  background: #2f2f2f;
  color: #ccc;
  padding: 30px 15px 10px;
}
.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 15px;
  max-width: 1100px;
  margin: auto;
}
.footer h3 { color: #fff; font-size: 15px; margin-bottom: 8px; }
.footer a { color: #ffcc00; font-size: 14px; }
.footer .social-links img {
  width: 24px;
  height: 24px;
  filter: brightness(0.9);
}
.footer .social-links img:hover { filter: brightness(1.3); }
.footer-bottom {
  text-align: center;
  border-top: 1px solid #444;
  padding-top: 10px;
  margin-top: 15px;
  font-size: 13px;
}

/* ===== واکنش‌گرایی ===== */
@media (max-width: 768px) {
  .about-content, .contact-container { flex-direction: column; }
  .hero { padding: 50px 10px; }
  .hero h1 { font-size: 22px; }
  .service-box, .gallery-container img, .about-image img { max-width: 100%; }
}
.gallery-item img {
  transition: transform 0.4s ease, filter 0.4s ease;
}
.gallery-item img:hover {
  transform: scale(1.05);
  filter: brightness(1.1);
}
/* ===========================
   انیمیشن ظاهر شدن (fade-in)
=========================== */
.fade-in {
  opacity: 0;
  transform: translateY(25px);
  transition: all 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}
/* ===== Lightbox Style ===== */
.lightbox {
  display: none; /* پنهان تا وقتی عکس کلیک نشده */
  position: fixed;
  z-index: 999;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  justify-content: center;
  align-items: center;
}

.lightbox img {
  max-width: 90%;
  max-height: 80%;
  border-radius: 10px;
  box-shadow: 0 0 15px rgba(255,255,255,0.4);
  animation: fadeIn 0.4s ease;
}

.lightbox.active {
  display: flex;
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 25px;
  font-size: 28px;
  color: #fff;
  cursor: pointer;
  transition: color 0.3s;
}
.lightbox-close:hover { color: #ffcc00; }
/* ===== چیدمان حرفه‌ای گالری 3+2 ===== */
.gallery-layout {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.gallery-row {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
  width: 100%;
}

.gallery-row img {
  width: 100%;
  max-width: 350px;
  height: 220px;
  object-fit: cover;
  border-radius: 10px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.gallery-row img:hover {
  transform: scale(1.05);
  box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

/* برای نسخه موبایل */
@media (max-width: 768px) {
  .gallery-row img {
    max-width: 100%;
    height: auto;
  }
}
/* ===== خط جداکننده بین بخش‌ها ===== */
.section-divider {
  width: 0%;
  height: 4px;
  background: linear-gradient(90deg, #cfa932, #ffcc00);
  margin: 40px auto;
  border-radius: 3px;
  opacity: 0;
  transition: all 1s ease;
}

/* وقتی در دید کاربر قرار گرفت */
.section-divider.visible {
  width: 80%;
  opacity: 1;
}

/* ===== خط طلایی تزئینی بالای تیترها ===== */
section h2 {
  position: relative;
  display: inline-block;
  text-align: center;
  margin-bottom: 40px;
}

section h2::before {
  content: "";
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, #d8b945, #ffcc00);
  border-radius: 2px;
  opacity: 0;
  transform: translateX(-50%) scaleX(0);
  transition: all 0.8s ease;
}

/* وقتی عنوان در دید کاربر قرار بگیره (با فید) */
.fade-in-title.visible::before {
  opacity: 1;
  transform: translateX(-50%) scaleX(1);
}
