/* ==========================================================================
   COSMIC ARCHITECTURAL LAYER v7 — دفتر وکالت روح‌الله کمال‌وند
   10 Lady Justice Portraits + Multi-Photo Practice Galleries + Section Banners
   + Case Path Advisor + Live Search + Two-Way Messaging + Owner Studio
   ========================================================================== */

#cosmicParticlesCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  opacity: 0.78;
}

.hero-code-label {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em !important;
  color: #E6C47A;
  opacity: 0.90;
  margin-bottom: 0.85rem;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(207, 168, 86, 0.08);
  border: 1px solid rgba(207, 168, 86, 0.24);
}
.hero-code-label span { color: rgba(230, 196, 122, 0.55); }
.hero-actions { position: relative; z-index: 3; }

.hero-principles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  max-width: 42rem;
}
.hero-principles > div {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.7rem 0.85rem;
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(16, 56, 42, 0.74), rgba(5, 22, 16, 0.88));
  border: 1px solid rgba(215, 182, 109, 0.24);
  color: #EAE4D3;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.55;
  box-shadow: 0 12px 28px -18px rgba(0, 0, 0, 0.85);
  transition: transform 0.28s ease, border-color 0.28s ease;
}
.hero-principles > div:hover {
  transform: translateY(-2px);
  border-color: rgba(232, 196, 118, 0.55);
}
.principle-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 9px;
  flex-shrink: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace !important;
  font-size: 11px;
  font-weight: 900;
  color: #061913;
  background: linear-gradient(135deg, #F4DBA0, #CFA856);
  box-shadow: 0 6px 16px -6px rgba(207, 168, 86, 0.75);
}

.hero-contact-card { position: relative; overflow: hidden; }
.hero-contact-icon {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 900;
  color: #E6C47A;
  background: rgba(207, 168, 86, 0.14);
  border: 1px solid rgba(207, 168, 86, 0.30);
}

/* ==========================================================================
   Lady Justice Stage & 10-Statue Interactive Gallery Controls
   ========================================================================== */
.justice-stage-wrap {
  position: relative;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1200px;
}

@keyframes orbitSpinCW {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to   { transform: translate(-50%, -50%) rotate(360deg); }
}
@keyframes orbitSpinCCW {
  from { transform: translate(-50%, -50%) rotate(360deg); }
  to   { transform: translate(-50%, -50%) rotate(0deg); }
}
@keyframes sealPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(215, 182, 109, 0.38), 0 14px 32px rgba(0,0,0,0.55); }
  50%      { box-shadow: 0 0 0 10px rgba(215, 182, 109, 0.0), 0 18px 38px rgba(0,0,0,0.68); }
}

.justice-orbit {
  position: absolute;
  top: 50%;
  left: 50%;
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
}
.justice-orbit.orbit-one {
  width: 104%;
  aspect-ratio: 1;
  border: 1px dashed rgba(215, 182, 109, 0.30);
  animation: orbitSpinCW 64s linear infinite;
}
.justice-orbit.orbit-two {
  width: 115%;
  aspect-ratio: 1;
  border: 1px solid rgba(215, 182, 109, 0.14);
  box-shadow: inset 0 0 40px rgba(207, 168, 86, 0.05);
  animation: orbitSpinCCW 92s linear infinite;
}
.justice-orbit.orbit-three {
  width: 92%;
  aspect-ratio: 1;
  border: 1px dotted rgba(243, 219, 159, 0.24);
  animation: orbitSpinCW 48s linear infinite;
}

.justice-stage {
  position: relative;
  z-index: 2;
  width: 100%;
  height: clamp(505px, 48vw, 635px);
  border-radius: 280px 280px 36px 36px;
  border: 1.5px solid rgba(232, 196, 118, 0.75);
  background:
    radial-gradient(ellipse at 50% 24%, rgba(215, 182, 109, 0.28), transparent 60%),
    linear-gradient(180deg, #123E2D 0%, #061A13 78%, #03100C 100%);
  box-shadow:
    0 46px 112px -38px rgba(0, 0, 0, 0.94),
    0 0 0 8px rgba(215, 182, 109, 0.07),
    0 0 0 18px rgba(215, 182, 109, 0.03),
    inset 0 1px 0 rgba(255, 248, 224, 0.35);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease;
  transform-style: preserve-3d;
}
.justice-stage::before {
  content: '';
  position: absolute;
  inset: 11px;
  z-index: 3;
  border: 1px solid rgba(239, 211, 151, 0.38);
  border-radius: 268px 268px 26px 26px;
  pointer-events: none;
}

.lady-justice-hero {
  transition: opacity 0.4s ease, transform 0.55s ease;
}

.justice-stage-shade {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(4, 18, 14, 0.06) 0%, transparent 32%, transparent 66%, rgba(3, 14, 10, 0.86) 100%),
    radial-gradient(circle at 50% 50%, transparent 60%, rgba(3, 14, 10, 0.42) 100%);
}

.justice-stage-seal {
  position: absolute;
  top: 26px;
  left: 26px;
  z-index: 4;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #F4DBA0;
  background: radial-gradient(circle at 30% 25%, rgba(22, 74, 54, 0.94), rgba(4, 18, 14, 0.94));
  border: 1.5px solid rgba(232, 196, 118, 0.65);
  animation: sealPulse 4s ease-in-out infinite;
  cursor: pointer;
}
.justice-stage-seal svg { width: 32px; height: 32px; }

.hero-justice-bar {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.42rem 0.75rem;
  border-radius: 999px;
  white-space: nowrap;
  font-size: 11px;
  font-weight: 800;
  color: #F7E7C3;
  background: rgba(3, 18, 13, 0.86);
  border: 1px solid rgba(232, 196, 118, 0.52);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.55);
}
.hero-justice-nav-btn {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(232, 196, 118, 0.16);
  color: #F7E7C3;
  font-size: 12px;
  font-weight: 900;
  transition: background-color 0.2s ease, transform 0.2s ease;
}
.hero-justice-nav-btn:hover {
  background: rgba(232, 196, 118, 0.36);
  transform: scale(1.08);
}
.tag-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #E6C47A;
  box-shadow: 0 0 10px #E6C47A;
  flex-shrink: 0;
}

.hero-orbit-label {
  position: absolute;
  z-index: 5;
  padding: 0.42rem 0.85rem;
  border-radius: 999px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace !important;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.11em !important;
  color: rgba(244, 225, 178, 0.86);
  background: rgba(5, 22, 16, 0.84);
  border: 1px solid rgba(215, 182, 109, 0.34);
  backdrop-filter: blur(10px);
  box-shadow: 0 12px 28px -12px rgba(0, 0, 0, 0.8);
  pointer-events: none;
}
.hero-orbit-label b { color: #E6C47A; font-weight: 900; margin-inline-start: 0.35rem; }
.orbit-label-top { top: 6px; right: 12px; }
.orbit-label-bottom { bottom: 4px; left: 12px; }

.justice-side-note {
  position: absolute;
  bottom: 74px;
  right: -12px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.75rem 1rem;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(16, 56, 42, 0.92), rgba(4, 18, 14, 0.95));
  border: 1px solid rgba(232, 196, 118, 0.46);
  box-shadow: 0 20px 44px -18px rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(14px);
}
.justice-side-note span {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace !important;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.16em !important;
  color: #CFA856;
}
.justice-side-note b { font-size: 12px; font-weight: 900; color: #F8F4E9; }
.justice-side-note small { font-size: 11px; font-weight: 700; color: #E6C47A; }

.hero-bottom-line {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(215, 182, 109, 0.22);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}
.hero-bottom-line > div {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1.1rem;
  border-radius: 18px;
  background: rgba(12, 44, 33, 0.52);
  border: 1px solid rgba(215, 182, 109, 0.18);
  color: #E5DFD0;
  font-size: 13px;
  font-weight: 700;
}
.hero-bottom-line svg { width: 22px; height: 22px; color: #E6C47A; flex-shrink: 0; }

/* ==========================================================================
   Multi-Photo Practice Area Carousel & Section Editorial Banners
   ========================================================================== */
.practice-card {
  position: relative;
  transform-style: preserve-3d;
}
.practice-gallery-frame {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  border: 1px solid color-mix(in srgb, var(--accent) 44%, transparent);
  box-shadow: 0 18px 38px -20px rgba(0, 0, 0, 0.72);
}
.practice-visual-banner {
  width: 100%;
  height: 225px;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1), filter 0.45s ease;
}
.practice-card:hover .practice-visual-banner {
  transform: scale(1.035);
  filter: contrast(1.05) brightness(1.04);
}
.gallery-controls-bar {
  position: absolute;
  bottom: 10px;
  inset-inline: 10px;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.35rem 0.65rem;
  border-radius: 12px;
  background: rgba(4, 18, 14, 0.76);
  border: 1px solid rgba(232, 196, 118, 0.34);
  backdrop-filter: blur(8px);
}
.gallery-dots {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.gallery-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  transition: width 0.25s ease, background-color 0.25s ease;
}
.gallery-dot.is-active {
  width: 20px;
  background: #E6C47A;
}
.gallery-arrow-btn {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(232, 196, 118, 0.18);
  color: #F7E7C3;
  font-size: 12px;
  font-weight: 900;
}
.gallery-arrow-btn:hover { background: rgba(232, 196, 118, 0.38); }

/* Editorial Section Visual Banners */
.section-editorial-banner {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--accent) 38%, transparent);
  box-shadow: 0 22px 50px -26px rgba(0, 0, 0, 0.75);
}
.section-editorial-banner img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  display: block;
}
.section-editorial-caption {
  position: absolute;
  bottom: 0;
  inset-inline: 0;
  padding: 0.75rem 1.15rem;
  background: linear-gradient(0deg, rgba(4, 18, 14, 0.90) 0%, rgba(4, 18, 14, 0.45) 70%, transparent 100%);
  color: #F6EBD0;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.card-glare {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease;
  background: radial-gradient(circle 280px at var(--mx, 50%) var(--my, 50%), rgba(244, 219, 160, 0.13), transparent 75%);
  z-index: 3;
}
.practice-card:hover .card-glare,
.justice-stage:hover .card-glare { opacity: 1; }

.tool-result-box {
  border-radius: 22px;
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  background:
    radial-gradient(circle at 15% 15%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 65%),
    color-mix(in srgb, var(--bg-surface) 92%, transparent);
}

/* Font-size accessibility modes */
html.font-scale-lg { font-size: 110%; }
html.font-scale-xl { font-size: 120%; }

/* Mobile Quick-Conversion Floating Bar */
.mobile-conversion { display: none; }
@media (max-width: 639px) {
  .mobile-conversion {
    position: fixed;
    bottom: calc(12px + env(safe-area-inset-bottom));
    inset-inline: 14px;
    z-index: 55;
    display: grid;
    grid-template-columns: 1fr 1.25fr;
    gap: 0.55rem;
    padding: 0.45rem;
    border-radius: 20px;
    background: color-mix(in srgb, var(--bg-header) 92%, #04120E);
    border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    box-shadow: 0 20px 44px -14px rgba(0, 0, 0, 0.85);
  }
  .mobile-conversion a,
  .mobile-conversion button {
    min-height: 44px;
    border-radius: 14px;
    font-size: 12px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
  }
  .mobile-conversion a {
    color: var(--text-main);
    background: color-mix(in srgb, var(--accent) 14%, transparent);
    border: 1px solid color-mix(in srgb, var(--accent) 34%, transparent);
  }
  .mobile-conversion button {
    color: var(--accent-contrast);
    background: linear-gradient(135deg, var(--accent-hover), var(--accent));
    box-shadow: 0 10px 22px -10px var(--accent);
  }
}

/* Floating Scroll-to-Top Circular Progress Ring Button */
#scrollTopRingBtn {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 52;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: color-mix(in srgb, var(--bg-card) 92%, transparent);
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  box-shadow: 0 14px 32px -12px rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(12px);
  opacity: 0;
  transform: translateY(14px) scale(0.9);
  pointer-events: none;
  transition: opacity 0.28s ease, transform 0.28s ease, border-color 0.25s ease;
}
#scrollTopRingBtn.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
#scrollTopRingBtn:hover {
  border-color: var(--accent);
  transform: translateY(-3px) scale(1.04);
}
#scrollTopRingBtn svg.progress-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
@media (max-width: 639px) {
  #scrollTopRingBtn {
    bottom: calc(78px + env(safe-area-inset-bottom));
    left: 14px;
    width: 42px;
    height: 42px;
  }
}

@media (max-width: 1023px) {
  .hero-principles, .hero-bottom-line { grid-template-columns: 1fr; }
  .justice-stage-wrap { padding: 1rem; }
}
@media (max-width: 639px) {
  .justice-stage {
    height: clamp(390px, 108vw, 450px);
    border-radius: 220px 220px 28px 28px;
  }
  .justice-stage::before { border-radius: 208px 208px 20px 20px; }
  .justice-side-note { right: 6px; bottom: 68px; padding: 0.55rem 0.75rem; }
  .hero-orbit-label { display: none; }
  .practice-visual-banner { height: 185px; }
  .section-editorial-banner img { height: 165px; }
}

@media print {
  #topAnnouncementBar, #siteHeader, #hero, #practice-areas, #case-advisor, #about-attorney, #testimonials, #faq, #contact,
  footer, .mobile-conversion, #scrollTopRingBtn, #bookingModal, #trackingModal, #vcardModal, #searchModal, #justiceLightboxModal, #ownerPinModal, #ownerPanelOverlay, #verdictsPage {
    display: none !important;
  }
  #document-guide {
    display: block !important;
    background: #FFFFFF !important;
    color: #000000 !important;
    padding: 0 !important;
  }
  #document-guide .t-card {
    box-shadow: none !important;
    border: 1px solid #CCCCCC !important;
    background: #FFFFFF !important;
  }
}
