/* ============================================
   Farhangian Plus - Dark Luxury Theme
   ============================================ */

:root {
  --bg-deep: #060a14;
  --bg-base: #0a0f1e;
  --bg-elevated: #101830;
  --bg-card: #0d1428;
  --border-soft: rgba(148, 178, 255, 0.12);
  --border-glow: rgba(94, 170, 255, 0.35);

  --blue-primary: #3b82f6;
  --blue-light: #60a5fa;
  --cyan: #22d3ee;
  --cyan-soft: #7dd3fc;
  --gold: #d4af37;
  --gold-light: #f4d976;
  --purple: #8b5cf6;

  --text-primary: #eef2ff;
  --text-secondary: #9aa8c7;
  --text-muted: #6b7690;

  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;

  --shadow-glow-blue: 0 0 40px rgba(59, 130, 246, 0.25);
  --shadow-glow-gold: 0 0 30px rgba(212, 175, 55, 0.18);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Vazirmatn', 'Tahoma', sans-serif;
  background: var(--bg-base);
  color: var(--text-primary);
  direction: rtl;
  margin: 0;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* Background ambience */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(ellipse 900px 500px at 15% -5%, rgba(59, 130, 246, 0.16), transparent 60%),
    radial-gradient(ellipse 700px 500px at 100% 10%, rgba(139, 92, 246, 0.12), transparent 60%),
    radial-gradient(ellipse 900px 600px at 50% 100%, rgba(212, 175, 55, 0.08), transparent 60%),
    linear-gradient(180deg, var(--bg-deep) 0%, var(--bg-base) 40%, #070b16 100%);
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  opacity: 0.35;
  background-image:
    linear-gradient(rgba(255,255,255,0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.015) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(ellipse 100% 60% at 50% 0%, black 40%, transparent 100%);
}

::selection {
  background: var(--blue-primary);
  color: #fff;
}

/* Scrollbar */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: linear-gradient(180deg, var(--blue-primary), var(--cyan)); border-radius: 10px; }

/* Utility: gradient text */
.gradient-text {
  background: linear-gradient(90deg, var(--cyan) 0%, var(--blue-light) 45%, var(--gold-light) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.gradient-text-gold {
  background: linear-gradient(120deg, var(--gold-light), var(--gold) 60%, #b8860b);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Glass card */
.glass-card {
  background: linear-gradient(160deg, rgba(20, 30, 55, 0.75), rgba(10, 15, 30, 0.65));
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.glass-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow-blue);
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: linear-gradient(90deg, var(--blue-primary), var(--cyan));
  color: #04101f;
  font-weight: 700;
  padding: 0.85rem 1.8rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(34, 211, 238, 0.25);
  font-family: inherit;
  font-size: 0.95rem;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(34, 211, 238, 0.4);
  filter: brightness(1.08);
}
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.btn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  color: #24190a;
  font-weight: 700;
  padding: 0.85rem 1.8rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(212, 175, 55, 0.25);
  font-family: inherit;
}
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 12px 32px rgba(212, 175, 55, 0.4); }

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: transparent;
  color: var(--text-primary);
  font-weight: 600;
  padding: 0.8rem 1.7rem;
  border-radius: 999px;
  border: 1px solid var(--border-glow);
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: inherit;
}
.btn-outline:hover { background: rgba(59,130,246,0.1); border-color: var(--cyan); }

.btn-ghost {
  background: rgba(148,178,255,0.06);
  border: 1px solid var(--border-soft);
  color: var(--text-primary);
  border-radius: var(--radius-sm);
  padding: 0.6rem 1rem;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.25s ease;
}
.btn-ghost:hover { background: rgba(148,178,255,0.12); }

/* Inputs */
.input-field {
  width: 100%;
  background: rgba(8, 12, 24, 0.7);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1.1rem;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  outline: none;
}
.input-field:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.15);
}
.input-field::placeholder { color: var(--text-muted); }

label.field-label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(6, 10, 20, 0.75);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-soft);
}

.nav-link {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.925rem;
  transition: color 0.25s ease;
  position: relative;
  text-decoration: none;
  padding: 0.4rem 0;
}
.nav-link:hover, .nav-link.active { color: var(--cyan-soft); }
.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  right: 0;
  left: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--cyan), var(--blue-primary));
  border-radius: 2px;
}

/* Logo glow */
.logo-glow {
  filter: drop-shadow(0 0 12px rgba(59, 130, 246, 0.5));
}

/* Badges */
.badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  color: #24190a;
}
.badge-blue {
  background: linear-gradient(90deg, var(--blue-primary), var(--cyan));
  color: #04101f;
}

/* Hero blob animation */
@keyframes float {
  0%, 100% { transform: translateY(0) translateX(0); }
  50% { transform: translateY(-20px) translateX(10px); }
}
.float-anim { animation: float 6s ease-in-out infinite; }
.float-anim-slow { animation: float 9s ease-in-out infinite; }
.float-anim-delay { animation: float 7s ease-in-out infinite 1.5s; }

@keyframes pulse-glow {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}
.pulse-glow { animation: pulse-glow 2.5s ease-in-out infinite; }

/* Fade in on scroll (JS opt-in via .js-reveal-ready to avoid hiding content when JS fails) */
.reveal {
  opacity: 1;
  transform: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.js-reveal-ready .reveal {
  opacity: 0;
  transform: translateY(24px);
}
.js-reveal-ready .reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Mobile menu */
.mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}
.mobile-menu.open {
  max-height: 500px;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(120%);
  background: var(--bg-elevated);
  border: 1px solid var(--border-glow);
  color: var(--text-primary);
  padding: 0.9rem 1.6rem;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 40px rgba(0,0,0,0.5);
  z-index: 200;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  font-size: 0.9rem;
  max-width: 90vw;
  text-align: center;
}
.toast.show { transform: translateX(-50%) translateY(0); }
.toast.error { border-color: #ef4444; }
.toast.success { border-color: #22c55e; }

/* Spinner */
.spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Table */
.table-luxury {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
.table-luxury th {
  background: rgba(59, 130, 246, 0.08);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.8rem;
  padding: 0.9rem 1rem;
  text-align: right;
  border-bottom: 1px solid var(--border-soft);
  white-space: nowrap;
}
.table-luxury td {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid rgba(148,178,255,0.06);
  font-size: 0.875rem;
  color: var(--text-primary);
  white-space: nowrap;
}
.table-luxury tr:hover td { background: rgba(59, 130, 246, 0.04); }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}
.status-pending { background: rgba(234, 179, 8, 0.15); color: #eab308; }
.status-processing { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.status-completed { background: rgba(34, 197, 94, 0.15); color: #22c55e; }
.status-canceled { background: rgba(239, 68, 68, 0.15); color: #ef4444; }

/* Responsive helpers */
@media (max-width: 767px) {
  .hide-mobile { display: none !important; }
}
@media (min-width: 768px) {
  .hide-desktop { display: none !important; }
}

/* Number font tabular for prices */
.tabular-nums { font-variant-numeric: tabular-nums; }

a { text-decoration: none; }

/* Custom checkbox / radio for service select cards */
.service-card {
  cursor: pointer;
  border: 1px solid var(--border-soft);
  transition: all 0.25s ease;
}
.service-card.selected {
  border-color: var(--cyan);
  box-shadow: 0 0 0 1px var(--cyan), var(--shadow-glow-blue);
  background: linear-gradient(160deg, rgba(34,211,238,0.08), rgba(10,15,30,0.65));
}

/* Loading skeleton */
.skeleton {
  background: linear-gradient(90deg, rgba(255,255,255,0.04) 25%, rgba(255,255,255,0.09) 37%, rgba(255,255,255,0.04) 63%);
  background-size: 400% 100%;
  animation: skeleton-loading 1.4s ease infinite;
  border-radius: 8px;
}
@keyframes skeleton-loading {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}
