/**
 * Valiasr Technical & Engineering Services - Base Styles & Typography
 */

@import url('https://cdn.jsdelivr.net/gh/rastikerdar/samim-font@v4.0.5/dist/font-face.css');

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: 'Samim', Tahoma, sans-serif !important;
  font-size: 16px;
  direction: rtl;
  text-align: right;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  max-width: 100vw;
}

body {
  font-family: 'Samim', Tahoma, sans-serif !important;
  line-height: 1.7;
  color: var(--text-primary);
  background-color: var(--bg-main);
  direction: rtl;
  text-align: right;
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

html, body, button, input, select, textarea, optgroup, a, p, span, h1, h2, h3, h4, h5, h6, li, td, th {
  font-family: 'Samim', Tahoma, sans-serif !important;
}

.icon-svg {
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: #25334a;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold-primary);
}

/* Typography Hierarchy */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

h1 {
  font-size: 2.5rem;
}
h2 {
  font-size: 2rem;
}
h3 {
  font-size: 1.5rem;
}
h4 {
  font-size: 1.25rem;
}

p {
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

img, svg, video {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Layout Utilities */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.main-content {
  flex: 1 0 auto;
}

.text-gold {
  color: var(--gold-primary) !important;
}

.text-gradient-gold {
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-muted {
  color: var(--text-muted) !important;
}

.text-center {
  text-align: center;
}

.section-padding {
  padding-top: 5rem;
  padding-bottom: 5rem;
}

.section-title-wrap {
  text-align: center;
  margin-bottom: 3.5rem;
  position: relative;
}

.section-subtitle {
  color: var(--gold-primary);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
  display: inline-block;
}

.section-title {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--text-primary);
}

.section-desc {
  max-width: 650px;
  margin: 0.75rem auto 0;
  color: var(--text-muted);
  font-size: 1rem;
}

/* Background Gradients & Glows */
.bg-glow-halo {
  position: relative;
}
.bg-glow-halo::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 500px;
  height: 500px;
  background: var(--gold-halo);
  pointer-events: none;
  z-index: 0;
}

/* Grid System */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.grid-5 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.25rem;
}

@media (max-width: 1024px) {
  .grid-5 {
    grid-template-columns: repeat(3, 1fr);
  }
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  h1 { font-size: 1.9rem; }
  h2 { font-size: 1.6rem; }
  .grid-5, .grid-4, .grid-3, .grid-2 {
    grid-template-columns: 1fr;
  }
  .section-padding {
    padding-top: 3.5rem;
    padding-bottom: 3.5rem;
  }
}
