/* ==========================================================================
   Barsava Theme - RTL Design inspired by Inva Template
   ========================================================================== */

/* CSS Variables */
:root {
  --primary-color: #d97706;
  --primary-hover: #b45309;
  --secondary-color: #6366f1;
  --accent-color: #f59e0b;
  --text-primary: #111827;
  --text-secondary: #6b7280;
  --text-light: #9ca3af;
  --bg-primary: #ffffff;
  --bg-secondary: #f9fafb;
  --bg-tertiary: #f3f4f6;
  --border-color: #e5e7eb;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-amber: 0 10px 15px -3px rgb(217 119 6 / 0.2);
}

/* RTL-specific adjustments */
[dir="rtl"] {
  .text-left { text-align: right !important; }
  .text-right { text-align: left !important; }
  .ml-auto, .margin-left-auto { margin-right: auto !important; margin-left: 0 !important; }
  .mr-auto, .margin-right-auto { margin-left: auto !important; margin-right: 0 !important; }
  .float-start { float: right !important; }
  .float-end { float: left !important; }
  .translate-x-1\/2 { transform: translatex(50%) !important; }
  .-translate-x-1\/2 { transform: translatex(-50%) !important; }
}
/* Base styles */
body {
  font-family: 'Vazirmatn', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #f3f4f6;
  color: #111827;
  line-height: 1.6;
  direction: rtl;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 800;
  color: #111827;
  line-height: 1.2;
}

a {
  color: #d97706;
  text-decoration: none;
  transition: all 0.3s ease;
}

a:hover {
  color: #b45309;
}

/* Amber accent color palette */
.text-amber-600 { color: #d97706 !important; }
.text-amber-400 { color: #fb923c !important; }
.text-amber-300 { color: #fdba74 !important; }
.text-amber-100 { color: #ffedd5 !important; }
.bg-amber-600 { background-color: #d97706 !important; }
.bg-amber-50 { background-color: #fffbeb !important; }
.bg-amber-100 { background-color: #ffedd5 !important; }
.border-amber-600 { border-color: #d97706 !important; }
.border-amber-200 { border-color: #fcd34d !important; }

/* Slate/gray palette */
.text-slate-900 { color: #111827 !important; }
.text-slate-700 { color: #374151 !important; }
.text-slate-600 { color: #4b5563 !important; }
.text-slate-500 { color: #6b7280 !important; }
.text-slate-400 { color: #9ca3af !important; }
.text-slate-300 { color: #d1d5db !important; }
.bg-gray-50 { background-color: #f9fafb !important; }
.bg-white { background-color: #ffffff !important; }
.bg-slate-900 { background-color: #111827 !important; }

/* Utility classes */
.rounded-xl { border-radius: 0.75rem !important; }
.rounded-2xl { border-radius: 1rem !important; }
.rounded-full { border-radius: 9999px !important; }
.shadow-sm { box-shadow: var(--shadow-sm) !important; }
.shadow-md { box-shadow: var(--shadow-md) !important; }
.shadow-lg { box-shadow: var(--shadow-lg) !important; }
.shadow-amber-200 { box-shadow: var(--shadow-amber) !important; }
.shadow-inner { box-shadow: inset 0 2px 4px 0 rgb(0 0 0 / 0.05); }

.font-black { font-weight: 900 !important; }
.font-bold { font-weight: 700 !important; }
.font-medium { font-weight: 500 !important; }

.transition-all { transition: all 0.3s ease; }
.transition-colors { transition: colors 0.3s ease; }

.backdrop-blur-sm { backdrop-filter: blur(4px); }

/* Layout containers */
.max-w-7xl { max-width: 80rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-xs { max-width: 20rem; }

.mx-auto { margin-left: auto; margin-right: auto; }
.mt-auto { margin-top: auto; }

/* Spacing */
.py-20 { padding-top: 5rem; padding-bottom: 5rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.px-4 { padding-right: 1rem; padding-left: 1rem; }
.px-6 { padding-right: 1.5rem; padding-left: 1.5rem; }
.px-8 { padding-right: 2rem; padding-left: 2rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.p-10 { padding: 2.5rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.mb-16 { margin-bottom: 4rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mr-2 { margin-left: 0.5rem; }
.ml-2 { margin-right: 0.5rem; }
.gap-2 { gap: 0.5rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }

/* Sizing */
.w-full { width: 100%; }
.w-2 { width: 0.5rem; }
.w-5 { width: 1.25rem; }
.w-8 { width: 2rem; }
.w-10 { width: 2.5rem; }
.w-12 { width: 3rem; }
.w-14 { width: 3.5rem; }
.w-16 { width: 4rem; }
.w-20 { width: 5rem; }
.w-96 { width: 24rem; }
.w-80 { width: 20rem; }
.w-64 { width: 16rem; }
.h-2 { height: 0.5rem; }
.h-5 { height: 1.25rem; }
.h-8 { height: 2rem; }
.h-10 { height: 2.5rem; }
.h-12 { height: 3rem; }
.h-14 { height: 3.5rem; }
.h-16 { height: 4rem; }
.h-20 { height: 5rem; }
.h-96 { height: 24rem; }
.h-80 { height: 20rem; }
.h-64 { height: 16rem; }
.h-full { height: 100%; }

/* Flexbox */
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.flex-1 { flex: 1 1 0%; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: 0.25rem; }

/* Grid */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.top-0 { top: 0; }
.left-0 { left: 0; }
.right-0 { right: 0; }
.bottom-0 { bottom: 0; }
.z-0 { z-index: 0; }
.z-50 { z-index: 50; }
.sticky { position: sticky; }
.top-0 { top: 0; }
.overflow-hidden { overflow: hidden; }

/* Display */
.block { display: block; }
.inline-block { display: inline-block; }
.hidden { display: none; }
/* Background gradients */
.bg-gradient-to-b { background-image: linear-gradient(to bottom, var(--tw-gradient-stops)); }
.bg-gradient-to-r { background-image: linear-gradient(to left, var(--tw-gradient-stops)); }
.from-slate-900 { --tw-gradient-from: #111827; --tw-gradient-to: rgb(17 24 39 / 0); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.via-slate-900 { --tw-gradient-stops: var(--tw-gradient-from), #111827, var(--tw-gradient-to); }
.to-slate-800 { --tw-gradient-to: #1f2937; }
.from-amber-600 { --tw-gradient-from: #d97706; --tw-gradient-to: rgb(217 119 6 / 0); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.to-transparent { --tw-gradient-to: transparent; }

/* Animations */
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}
.animate-pulse { animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite; }

/* Header and navigation */
.sticky.top-0 {
  top: 0;
}

.navbar-brand {
  font-weight: 800;
  font-size: 1.25rem;
  color: #111827;
}

.navbar-brand:hover {
  color: #d97706;
}

/* Buttons */
.btn {
  display: inline-block;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
  border: 1px solid transparent;
  padding: 0.5rem 1rem;
  border-radius: 0.75rem;
  font-size: 0.875rem;
  transition: all 0.3s ease;
}

.btn-primary {
  background-color: #d97706;
  border-color: #d97706;
  color: #ffffff;
}

.btn-primary:hover {
  background-color: #b45309;
  border-color: #b45309;
  color: #ffffff;
}

/* Component overrides for RTL */
.dropdown-menu {
  right: 0;
  left: auto;
}

[dir="rtl"] .dropdown-menu {
  right: auto;
  left: 0;
  text-align: right;
}

/* Form controls */
.form-control {
  direction: rtl;
  text-align: right;
}

/* Cards and sections */
.pazh-card, .service-card {
  transition: all 0.3s ease;
}

.pazh-card:hover, .service-card:hover {
  transform: translatey(-4px);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .py-20 { padding-top: 3rem; padding-bottom: 3rem; }
  .py-16 { padding-top: 2.5rem; padding-bottom: 2.5rem; }
  h1 { font-size: 2.5rem; }
  h2 { font-size: 2rem; }
  
  .grid-cols-2, .grid-cols-3, .grid-cols-4 {
    grid-template-columns: repeat(1, minmax(0, 1fr));
  }
  
  .text-4xl { font-size: 2rem; }
  .text-3xl { font-size: 1.75rem; }
}
.shrink-0 { flex-shrink: 0; }
.flex-shrink-0 { flex-shrink: 0; }

/* Borders */
.border { border-width: 1px; }
.border-t { border-top-width: 1px; }
.border-b { border-bottom-width: 1px; }
.border-y { border-top-width: 1px; border-bottom-width: 1px; }
.border-gray-100 { border-color: #f3f4f6; }
.border-gray-200 { border-color: #e5e7eb; }
.border-white\/20 { border-color: rgba(255, 255, 255, 0.2); }
.border-white\/30 { border-color: rgba(255, 255, 255, 0.3); }

/* Opacity */
.opacity-20 { opacity: 0.2; }
.opacity-10 { opacity: 0.1; }
.opacity-60 { opacity: 0.6; }

/* Extra utilities used by the Events / Event pages */
.min-h-screen { min-height: 100vh; }
.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-3xl { font-size: 2rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.5rem; line-height: 2.75rem; }
.h-52 { height: 13rem; }
.px-2 { padding-right: 0.5rem; padding-left: 0.5rem; }
.px-3 { padding-right: 0.75rem; padding-left: 0.75rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mt-2 { margin-top: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.line-clamp-1, .line-clamp-2 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-1 { -webkit-line-clamp: 1; }
.line-clamp-2 { -webkit-line-clamp: 2; }
