/* ═══════════════════════════════════════════
   وکیل فرد — Minimal Modern Enhancements
═══════════════════════════════════════════ */

:root {
  --navy-950: #060a12;
  --navy-900: #0a1220;
  --navy-800: #101b2e;
  --navy-700: #162338;
  --navy-600: #1e2f4a;
  --gold-400: #d4b45a;
  --gold-500: #c4a14a;
  --gold-600: #9a7d2e;
  --silver: #b8c2d0;
  --white: #f4f6f9;
  --muted: #7d8a9c;
  --line: rgba(196, 161, 74, 0.12);
  --radius: 12px;
  --radius-lg: 18px;
  --header-h: 72px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

body {
  background: var(--navy-950);
  letter-spacing: -0.01em;
}

.container {
  width: min(100% - 2rem, 1120px);
}

/* Soft ambient — less busy circuit */
.circuit-bg::before {
  background-image:
    linear-gradient(rgba(196, 161, 74, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(196, 161, 74, 0.025) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: 0.7;
}

/* ── Buttons: attractive hover ── */
.btn {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding: 0.9rem 1.75rem;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0;
  transition:
    transform 0.35s var(--ease-out),
    box-shadow 0.35s var(--ease-out),
    background 0.35s,
    border-color 0.35s,
    color 0.35s;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 35%,
    rgba(255, 255, 255, 0.35) 50%,
    transparent 65%
  );
  transform: translateX(120%);
  transition: transform 0.65s var(--ease-out);
  z-index: 0;
  pointer-events: none;
}

.btn > * ,
.btn {
  z-index: 1;
}

.btn:hover {
  transform: translateY(-3px);
}

.btn:hover::before {
  transform: translateX(-120%);
}

.btn:active {
  transform: translateY(-1px) scale(0.98);
}

.btn-primary {
  background: linear-gradient(135deg, #e0c56a 0%, var(--gold-500) 50%, var(--gold-600) 100%);
  color: #0a1220;
  border: none;
  box-shadow:
    0 4px 16px rgba(196, 161, 74, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.btn-primary:hover {
  box-shadow:
    0 12px 36px rgba(196, 161, 74, 0.38),
    0 0 0 1px rgba(196, 161, 74, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  filter: brightness(1.05);
}

.btn-ghost {
  background: transparent;
  border-color: rgba(184, 194, 208, 0.22);
  color: var(--white);
}

.btn-ghost:hover {
  border-color: var(--gold-500);
  color: var(--gold-400);
  background: rgba(196, 161, 74, 0.08);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.2);
}

.btn-outline-gold {
  border-color: rgba(196, 161, 74, 0.45);
  color: var(--gold-400);
  background: transparent;
}

.btn-outline-gold:hover {
  background: rgba(196, 161, 74, 0.12);
  border-color: var(--gold-400);
  box-shadow: 0 8px 28px rgba(196, 161, 74, 0.18);
}

.btn-sm {
  padding: 0.55rem 1.2rem;
  font-size: 0.85rem;
}

/* ── Header minimal ── */
.site-header.scrolled {
  background: rgba(6, 10, 18, 0.82);
  backdrop-filter: blur(20px) saturate(1.2);
  box-shadow: none;
  border-bottom: 1px solid var(--line);
}

.nav > li > a,
.nav-trigger {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--muted);
}

.nav > li > a:hover,
.nav-trigger:hover,
.nav > li > a.active {
  color: var(--white);
  background: rgba(255, 255, 255, 0.04);
}

.brand-logo {
  width: 46px;
  height: 46px;
  border-width: 1px;
  box-shadow: none;
}

.brand-name { font-size: 1rem; font-weight: 700; }
.brand-sub { font-size: 0.68rem; color: var(--muted); }

/* ── Hero cleaner ── */
.hero-brand {
  font-size: clamp(2.2rem, 5.5vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.hero h1 {
  font-weight: 500;
  color: var(--silver);
}

.hero .lead {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.9;
}

/* ── Service items: minimal hover ── */
.service-item {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  padding: 1.6rem 1.35rem;
  transition:
    border-color 0.35s var(--ease),
    transform 0.35s var(--ease-out),
    background 0.35s,
    box-shadow 0.35s;
}

.service-item:hover {
  border-color: rgba(196, 161, 74, 0.35);
  background: rgba(196, 161, 74, 0.04);
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
}

.service-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(196, 161, 74, 0.08);
  font-size: 1.1rem;
  font-weight: 700;
  transition: background 0.3s, transform 0.35s var(--ease-out);
}

.service-item:hover .service-icon {
  background: rgba(196, 161, 74, 0.18);
  transform: scale(1.08);
}

.service-item p { font-size: 0.88rem; }
.service-item .link-more {
  opacity: 0.7;
  transition: opacity 0.25s, gap 0.25s;
  gap: 0.25rem;
}
.service-item:hover .link-more {
  opacity: 1;
  gap: 0.5rem;
}

/* ── Process: connected timeline ── */
.process {
  position: relative;
  gap: 1.25rem;
}

.process::before {
  content: '';
  position: absolute;
  top: 2.2rem;
  right: 8%;
  left: 8%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(196, 161, 74, 0.35), transparent);
  pointer-events: none;
}

.process-step {
  padding: 1.25rem 1rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  background: rgba(16, 27, 46, 0.4);
  transition: border-color 0.3s, transform 0.35s var(--ease-out), background 0.3s;
}

.process-step:hover {
  border-color: rgba(196, 161, 74, 0.3);
  transform: translateY(-4px);
  background: rgba(22, 35, 56, 0.65);
}

.process-step::before {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--gold-500);
  opacity: 0.55;
  margin-bottom: 0.85rem;
  position: relative;
  z-index: 1;
}

.process-step h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.process-step p {
  font-size: 0.86rem;
  line-height: 1.75;
  color: var(--muted);
}

/* ── AI Consultant section ── */
.ai-section {
  position: relative;
  overflow: hidden;
}

.ai-panel {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2.5rem;
  align-items: center;
  padding: 2.5rem;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(ellipse 60% 80% at 100% 0%, rgba(196, 161, 74, 0.1), transparent 55%),
    linear-gradient(160deg, rgba(22, 35, 56, 0.7), rgba(10, 18, 32, 0.9));
}

.ai-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(61, 155, 106, 0.35);
  background: rgba(61, 155, 106, 0.1);
  color: #5ecf90;
  font-size: 0.78rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.ai-badge::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #5ecf90;
  box-shadow: 0 0 0 3px rgba(94, 207, 144, 0.25);
  animation: pulse-dot 1.8s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 3px rgba(94, 207, 144, 0.25); }
  50% { opacity: 0.7; box-shadow: 0 0 0 6px rgba(94, 207, 144, 0.08); }
}

.ai-copy h2 { margin-bottom: 0.75rem; }
.ai-copy .lead { margin-bottom: 1.5rem; }

.ai-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.ai-chip {
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: var(--silver);
  font-size: 0.8rem;
  cursor: pointer;
  transition: border-color 0.25s, color 0.25s, background 0.25s, transform 0.25s var(--ease-out);
}

.ai-chip:hover {
  border-color: rgba(196, 161, 74, 0.4);
  color: var(--gold-400);
  background: rgba(196, 161, 74, 0.08);
  transform: translateY(-2px);
}

.ai-preview {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: rgba(6, 10, 18, 0.55);
  overflow: hidden;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.3);
}

.ai-preview-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(16, 27, 46, 0.8);
}

.ai-preview-head img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--gold-500);
  object-fit: cover;
}

.ai-preview-head strong {
  display: block;
  font-size: 0.88rem;
}

.ai-preview-head span {
  font-size: 0.72rem;
  color: #5ecf90;
}

.ai-preview-body {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  min-height: 180px;
}

.ai-preview-body .bubble {
  max-width: 90%;
  padding: 0.7rem 0.95rem;
  border-radius: 12px;
  font-size: 0.82rem;
  line-height: 1.7;
  color: var(--silver);
  background: var(--navy-700);
  border-bottom-right-radius: 4px;
}

.ai-preview-body .bubble.user {
  align-self: flex-end;
  background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
  color: #0a1220;
  border-bottom-right-radius: 12px;
  border-bottom-left-radius: 4px;
  font-weight: 500;
}

.ai-preview-foot {
  padding: 0.75rem 1rem 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.ai-preview-foot .btn {
  width: 100%;
}

/* ── Stats minimal ── */
.stat {
  background: transparent;
  border-top: 1px solid rgba(196, 161, 74, 0.35);
  border-bottom: none;
  padding: 1.35rem 0.75rem;
}

.stat-num {
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* ── Articles: underline hover ── */
.article-card {
  border-bottom-color: rgba(255, 255, 255, 0.06);
  padding-bottom: 1.35rem;
}

.article-card:hover {
  border-bottom-color: var(--gold-500);
}

.article-card h3 {
  font-weight: 600;
  font-size: 1.05rem;
}

/* ── FAQ cleaner ── */
.faq-q {
  font-weight: 500;
  font-size: 0.98rem;
  transition: color 0.2s;
}

.faq-q:hover {
  color: var(--gold-400);
}

.faq-item {
  border-bottom-color: rgba(255, 255, 255, 0.06);
}

/* ── CTA softer ── */
.cta-band {
  background:
    radial-gradient(ellipse 50% 70% at 50% 50%, rgba(196, 161, 74, 0.08), transparent),
    var(--navy-900);
}

/* ── Chatbot polish ── */
.chat-fab {
  width: 58px;
  height: 58px;
  background: linear-gradient(145deg, #e0c56a, var(--gold-600));
  box-shadow:
    0 8px 28px rgba(196, 161, 74, 0.35),
    0 0 0 0 rgba(196, 161, 74, 0.4);
  animation: fab-pulse 2.8s ease-in-out infinite;
}

@keyframes fab-pulse {
  0%, 100% { box-shadow: 0 8px 28px rgba(196, 161, 74, 0.35), 0 0 0 0 rgba(196, 161, 74, 0.35); }
  50% { box-shadow: 0 8px 28px rgba(196, 161, 74, 0.45), 0 0 0 12px rgba(196, 161, 74, 0); }
}

.chat-fab:hover {
  transform: scale(1.08);
  animation: none;
}

.chat-fab-label {
  position: absolute;
  right: calc(100% + 10px);
  top: 50%;
  transform: translateY(-50%);
  white-space: nowrap;
  padding: 0.4rem 0.75rem;
  border-radius: 8px;
  background: var(--navy-800);
  border: 1px solid var(--line);
  color: var(--white);
  font-size: 0.75rem;
  font-weight: 600;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s;
}

.chat-fab:hover .chat-fab-label {
  opacity: 1;
}

.chat-panel {
  border-radius: 18px;
  border-color: rgba(196, 161, 74, 0.2);
  background: var(--navy-900);
}

.chat-head {
  background: linear-gradient(135deg, var(--navy-800), var(--navy-950));
}

.msg-bot {
  background: var(--navy-800);
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.chat-quick button {
  transition: border-color 0.2s, color 0.2s, background 0.2s, transform 0.2s;
}

.chat-quick button:hover {
  transform: translateY(-2px);
  background: rgba(196, 161, 74, 0.08);
}

.chat-typing {
  display: inline-flex;
  gap: 4px;
  padding: 0.85rem 1rem;
  align-self: flex-start;
  background: var(--navy-800);
  border-radius: 14px;
  border-bottom-right-radius: 4px;
}

.chat-typing i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
  animation: typing 1.2s ease-in-out infinite;
}

.chat-typing i:nth-child(2) { animation-delay: 0.15s; }
.chat-typing i:nth-child(3) { animation-delay: 0.3s; }

@keyframes typing {
  0%, 60%, 100% { opacity: 0.3; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-3px); }
}

/* ── Section spacing ── */
.section {
  padding: 5rem 0;
}

.section-alt {
  background: linear-gradient(180deg, rgba(10, 18, 32, 0.9), var(--navy-950));
  border-block-color: rgba(255, 255, 255, 0.04);
}

.section-head {
  margin-bottom: 2.5rem;
}

.eyebrow {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: none;
}

/* ── Footer quieter ── */
.site-footer {
  background: var(--navy-950);
  border-top-color: rgba(255, 255, 255, 0.05);
}

.footer-col a {
  transition: color 0.2s, padding-right 0.25s;
}

.footer-col a:hover {
  padding-right: 4px;
}

/* ── Responsive refinements ── */
@media (max-width: 1024px) {
  .ai-panel {
    grid-template-columns: 1fr;
    gap: 1.75rem;
    padding: 1.75rem;
  }

  .process::before {
    display: none;
  }
}

@media (max-width: 860px) {
  :root { --header-h: 64px; }

  .hero-content {
    padding: 2.5rem 0 3.5rem;
    max-width: 100%;
  }

  .hero-brand {
    font-size: clamp(1.9rem, 9vw, 2.6rem);
  }

  .hero h1 {
    font-size: 1.15rem;
  }

  .ai-preview {
    max-width: 400px;
    margin-inline: auto;
  }

  .chat-fab-label {
    display: none;
  }

  .section {
    padding: 3.25rem 0;
  }

  .about-strip {
    gap: 1.75rem;
  }
}

@media (max-width: 600px) {
  .container {
    width: min(100% - 1.5rem, var(--max));
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .ai-panel {
    padding: 1.25rem;
    border-radius: 16px;
  }

  .ai-chips {
    gap: 0.4rem;
  }

  .ai-chip {
    font-size: 0.74rem;
    padding: 0.4rem 0.7rem;
  }

  .process-step {
    padding: 1rem;
  }

  .cta-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .cta-actions .btn {
    width: 100%;
  }

  .chat-fab {
    width: 52px;
    height: 52px;
    bottom: 1rem;
    left: 1rem;
  }

  .chat-panel {
    width: calc(100vw - 1.25rem);
    left: 0.625rem;
    bottom: 4.5rem;
    height: min(70vh, 520px);
  }

  .stats {
    gap: 0.5rem;
  }

  .stat {
    padding: 1rem 0.5rem;
  }

  .stat-num {
    font-size: 1.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn::before,
  .chat-fab,
  .ai-badge::before {
    animation: none !important;
    transition: none !important;
  }
}
