/* ============================================================================
   هرکجا | MTheme — صفحه جزئیات کسب‌وکار (S/I) — detail.css
   تم روشن · Glass · Ambient · App-like
   ⚠️ کلاس‌های عملکردی JS (open360Btn, btncall-customer, btn-360, tourcall,
      modal360, modalVideo, swipeHint, floating_btn, ...) عیناً حفظ شده‌اند.
   ============================================================================ */

/* ---------- سربرگ صفحه ---------- */
.pd-header { position: relative; padding-block: clamp(28px, 4vw, 52px) clamp(24px, 3vw, 40px); }
.pd-header .pd-caption h1 {
  font-size: clamp(1.6rem, 4.4vw, 2.8rem); font-weight: 800; margin: 0 0 10px;
  color: var(--ink); min-height: 1.4em;
}
.pd-cat { color: var(--brand); font-weight: 700; font-size: 0.92rem; display: inline-block; }

/* بلوک‌های تماس */
.pd-contacts { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.pd-contact {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border-radius: 16px;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--glass-blur-sm)); -webkit-backdrop-filter: blur(var(--glass-blur-sm));
  box-shadow: var(--glass-shadow-sm); min-width: 200px;
}
.pd-contact .pd-c-icon {
  width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0;
  background: var(--brand-soft); color: var(--brand);
  display: flex; align-items: center; justify-content: center; font-size: 1.05rem;
}
.pd-contact .pd-c-label { display: block; color: var(--muted); font-size: 0.76rem; }
.pd-contact a, .pd-contact h6 { color: var(--ink); font-weight: 700; font-size: 0.95rem; margin: 0; direction: ltr; text-align: right; }
.pd-contact a:hover { color: var(--brand); }
.pd-contact .direc h6 { direction: rtl; font-size: 0.88rem; line-height: 1.6; }

/* مسیریابی (بلد/نشان/گوگل مپ) */
.pd-nav-cards { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.pd-nav-card {
  flex: 1; min-width: 110px; text-align: center; padding: 16px 12px; border-radius: 18px;
  background: var(--card); border: 1px solid var(--border); box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}
#mapsec{
    padding-top:25px;   
}
.section-padding {
    padding-top: 25px;
    padding-bottom: 25px;
}
.pd-nav-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
    border-color: transparent;
}
.pd-nav-card .icon-img-60 { width: 54px; height: 54px; margin: 0 auto 10px; display: flex; align-items: center; justify-content: center; }
.pd-nav-card .icon-img-60 img { width: 100%; height: 100%; object-fit: contain; }
.pd-nav-card span { color: var(--ink-soft); font-weight: 700; font-size: 0.85rem; }

/* هدر مسیریابی */
.pd-sec-head { margin-bottom: 22px; }
.pd-sec-head .eyebrow { display: inline-block; background: var(--brand-soft); color: var(--brand); font-size: 0.78rem; font-weight: 700; padding: 4px 13px; border-radius: 30px; margin-bottom: 12px; }

/* ---------- تصویر اصلی + ناحیه ۳۶۰ ---------- */
.pd-main-img { position: relative; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); margin-block: 8px 0; }
.pd-main-img img { width: 100%; display: block; }
.pd-main-img a { display: block; }

/* ---------- عنوان/توضیح ---------- */
.pd-intro { padding-block: clamp(26px, 4vw, 46px); }
.pd-intro h3 { font-size: clamp(1.3rem, 3.2vw, 1.9rem); margin-bottom: 14px; }
.pd-intro p { color: var(--ink-soft); font-size: 1rem; line-height: 1.9; }
.text-justify { text-align: justify !important; }

/* ---------- گالری (swiper) ---------- */
.pd-gallery { position: relative; margin-block: 8px 0; }
.pd-gallery .swiper-container { border-radius: var(--radius-lg); overflow: hidden; }
.pd-gallery .swiper-slide .bg-img {
  height: clamp(240px, 42vw, 460px);
  background-size: cover; background-position: center; background-repeat: no-repeat;
  display: flex; align-items: center; justify-content: center;
}
/* راهنمای کشیدن */
.swipe-hint { display: none; }
@media (max-width: 768px) {
  .swipe-hint {
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    color: var(--muted); font-size: 0.78rem; margin-bottom: 12px;
  }
  .swipe-hint .swipe-finger { width: 34px; height: 34px; color: var(--brand); animation: pd-swipe 1.8s ease-in-out infinite; }
  .swipe-hint .swipe-finger svg { width: 100%; height: 100%; }
  @keyframes pd-swipe { 0%,100% { transform: translateX(-8px); } 50% { transform: translateX(8px); } }
}
.lines, .vertical-line-arrows { display: none; }

/* ---------- دکمه شناور ۳۶۰ ---------- */
.floating_btn { position: fixed; bottom: 96px; right: 20px; z-index: 120; }
.floating_btn .btn-360 { position: relative; display: block; }
.floating_btn .contact_icon {
  width: 58px; height: 58px; border-radius: 50%;
  background: var(--brand); box-shadow: 0 10px 26px rgba(45,108,223,0.40);
  display: flex; align-items: center; justify-content: center; overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}
.floating_btn .contact_icon:hover { transform: translateY(-3px) scale(1.04); }
.floating_btn .contact_icon img { width: 32px; height: 32px; object-fit: contain; filter: brightness(0) invert(1); }
.floating_btn .tooltip-text {
  position: absolute; left: 70px; top: 50%; transform: translateY(-50%);
  background: var(--ink); color: #fff; font-size: 0.76rem; font-weight: 700;
  padding: 7px 12px; border-radius: 10px; white-space: nowrap; opacity: 0; pointer-events: none;
  transition: opacity var(--transition);
}
.floating_btn .btn-360:hover .tooltip-text { opacity: 1; }

/* ---------- مودال ۳۶۰ ---------- */
.modal-360-backdrop { position: fixed; inset: 0; background: rgba(20,33,61,0.55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); z-index: 400; display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal-360 {
  width: 100%; max-width: 1080px; height: min(84vh, 720px);
  background: var(--glass-bg-strong);
  backdrop-filter: blur(var(--glass-blur-lg)); -webkit-backdrop-filter: blur(var(--glass-blur-lg));
  border: 1px solid var(--glass-border); border-radius: 24px; overflow: hidden;
  display: flex; flex-direction: column; box-shadow: var(--glass-shadow);
}
.modal-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--glass-border-soft); }
.modal-title { font-weight: 800; color: var(--ink); font-size: 0.98rem; }
.modal-controls { display: flex; gap: 8px; }
.modal-controls button { background: var(--bg-soft); border: none;  border-radius: 11px; color: var(--ink); cursor: pointer; }
.modal-body { position: relative; flex: 1; background: var(--bg-cream); }
.modal-body iframe, .modal-body video, .modal-body img { width: 100%; height: 100%; border: 0; display: block; object-fit: contain; }
.loader { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.loader::after { content: ''; width: 42px; height: 42px; border-radius: 50%; border: 3px solid var(--brand-soft); border-top-color: var(--brand); animation: pd-spin 0.8s linear infinite; }
@keyframes pd-spin { to { transform: rotate(360deg); } }
.modal-360 .hint { padding: 10px 18px; color: var(--muted); font-size: 0.8rem; border-top: 1px solid var(--glass-border-soft); text-align: center; }

/* ---------- مودال ویدیو ---------- */
.video-modal { position: fixed; inset: 0; z-index: 410; display: flex; align-items: center; justify-content: center; padding: 16px; }
.video-modal-overlay { position: absolute; inset: 0; background: rgba(20,33,61,0.60); backdrop-filter: blur(6px); }
.video-modal-container { position: relative; width: 100%; max-width: 960px; z-index: 1; }
.video-modal-body { position: relative; background: #000; border-radius: 20px; overflow: hidden; box-shadow: var(--shadow-lg); }
.video-modal-close { position: absolute; top: 10px; left: 10px; z-index: 3; width: 38px; height: 38px; border-radius: 50%; border: none; background: rgba(255,255,255,0.92); color: var(--ink); font-size: 1.3rem; cursor: pointer; }
.video-wrapper video, .custom-video-player { width: 100%; display: block; }

/* ---------- خدمات ---------- */
.pd-services-title { text-align: center; font-size: clamp(1.15rem, 2.8vw, 1.6rem); margin-bottom: 28px; }
.serv_row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.serv_item {
  padding: 20px 18px; border-radius: 18px; text-align: center;
  background: var(--card); border: 1px solid var(--border); box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}
.serv_item:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.serv_text { margin: 0; font-weight: 700; color: var(--ink); font-size: 0.92rem; }

/* ---------- دکمه پلی ویدیو ---------- */
.play-button { display: flex; align-items: center; justify-content: center; }
.pd-video-thumb { position: relative; border-radius: var(--radius-lg); overflow: hidden; min-height: 260px; background-size: cover; background-position: center; display: flex; align-items: center; justify-content: center; }
.pd-video-thumb::after { content: ''; position: absolute; inset: 0; background: rgba(11,17,28,0.35); }
.butn-ply { position: relative; z-index: 2; display: flex; align-items: center; justify-content: center; }
.butn-ply svg { position: absolute; width: 80px; height: 80px; }
.butn-ply svg .circle { stroke: #fff; opacity: 0.6; }
.butn-ply i { position: relative; color: #fff; font-size: 1.5rem; }

/* ---------- پروژه‌ها / گالری کیهانی ---------- */
.projects-cosmic { padding-block: 30px; }
.projects-cosmic h3 { margin-bottom: 24px; }

/* ---------- ریسپانسیو ---------- */
@media (max-width: 1024px) { .serv_row { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 820px) {
  .serv_row { grid-template-columns: repeat(2, 1fr); }
  .pd-nav-cards { gap: 10px; }
  .pd-nav-card { min-width: calc(50% - 10px); }
}
@media (max-width: 600px) {
  .pd-contacts { flex-direction: column; }
  .pd-contact { width: 100%; }
  .pd-nav-card { min-width: 100%; }
  .serv_row { grid-template-columns: 1fr; }
  .floating_btn { bottom: 80px; right: 14px; }
  .floating_btn .contact_icon { width: 52px; height: 52px; }
  .modal-360 { height: min(88vh, 620px); border-radius: 18px; }
}
