/* ============================================
   BLUEFORGE AI - Design System & Styles
   Premium Enterprise Website
   ============================================ */

/* ============================================
   CSS CUSTOM PROPERTIES (Design Tokens)
   ============================================ */
:root {
  /* Colors */
  --primary: #0a2463;
  --primary-light: #1e4d8c;
  --primary-dark: #051633;
  --accent: #3e92cc;
  --accent-light: #5ba8d9;
  --white: #ffffff;
  --grey-light: #f8f9fa;
  --grey: #6c757d;
  --grey-dark: #343a40;
  --success: #28a745;
  --gradient-primary: linear-gradient(135deg, #0a2463 0%, #1e4d8c 50%, #3e92cc 100%);
  --gradient-hero: linear-gradient(135deg, #051633 0%, #0a2463 50%, #1e4d8c 100%);
  --gradient-card: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);

  /* Typography */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 2rem;
  --font-size-4xl: 2.5rem;
  --font-size-5xl: 3.5rem;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Layout */
  --container-max: 1200px;
  --container-narrow: 900px;
  --border-radius: 8px;
  --border-radius-lg: 16px;
  --border-radius-xl: 24px;

  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(10, 36, 99, 0.05);
  --shadow-md: 0 4px 12px rgba(10, 36, 99, 0.1);
  --shadow-lg: 0 8px 24px rgba(10, 36, 99, 0.15);
  --shadow-xl: 0 16px 48px rgba(10, 36, 99, 0.2);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 300ms ease;
  --transition-slow: 500ms ease;
}

/* ============================================
   RESET & BASE STYLES
   ============================================ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-primary);
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--grey-dark);
  background-color: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

a:hover {
  color: var(--primary-light);
}

ul,
ol {
  list-style: none;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.2;
  color: var(--primary);
}

h1 {
  font-size: clamp(2.5rem, 5vw, var(--font-size-5xl));
}

h2 {
  font-size: clamp(2rem, 4vw, var(--font-size-4xl));
}

h3 {
  font-size: clamp(1.5rem, 3vw, var(--font-size-3xl));
}

h4 {
  font-size: var(--font-size-xl);
}

p {
  margin-bottom: var(--space-md);
}

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

.text-accent {
  color: var(--accent);
}

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

/* ============================================
   LAYOUT
   ============================================ */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.container-narrow {
  max-width: var(--container-narrow);
}

.section {
  padding: var(--space-4xl) 0;
}

.section-alt {
  background-color: var(--grey-light);
}

.section-dark {
  background: var(--gradient-hero);
  color: var(--white);
}

.section-dark h2,
.section-dark h3 {
  color: var(--white);
}

.grid {
  display: grid;
  gap: var(--space-xl);
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.flex {
  display: flex;
}

.flex-center {
  justify-content: center;
  align-items: center;
}

.flex-between {
  justify-content: space-between;
  align-items: center;
}

.gap-sm {
  gap: var(--space-sm);
}

.gap-md {
  gap: var(--space-md);
}

.gap-lg {
  gap: var(--space-lg);
}

.gap-xl {
  gap: var(--space-xl);
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(10, 36, 99, 0.1);
  transition: all var(--transition-base);
}

.header.scrolled {
  box-shadow: var(--shadow-md);
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 80px;
}

.logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--primary);
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: var(--gradient-primary);
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-weight: 700;
  font-size: var(--font-size-lg);
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
}

.nav-links {
  display: flex;
  gap: var(--space-lg);
}

.nav-link {
  font-weight: 500;
  color: var(--grey-dark);
  padding: var(--space-sm) 0;
  position: relative;
  transition: color var(--transition-fast);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width var(--transition-base);
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: var(--space-sm);
}

.mobile-toggle span {
  width: 24px;
  height: 2px;
  background: var(--primary);
  transition: all var(--transition-fast);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  font-family: var(--font-primary);
  font-size: var(--font-size-base);
  font-weight: 600;
  text-align: center;
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: all var(--transition-base);
  white-space: nowrap;
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--white);
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  color: var(--white);
}

.btn-secondary {
  background: var(--white);
  color: var(--primary);
  border: 2px solid var(--primary);
}

.btn-secondary:hover {
  background: var(--primary);
  color: var(--white);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border: 2px solid var(--white);
}

.btn-outline:hover {
  background: var(--white);
  color: var(--primary);
}

.btn-lg {
  padding: var(--space-lg) var(--space-2xl);
  font-size: var(--font-size-lg);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: var(--gradient-hero);
  position: relative;
  overflow: hidden;
  padding-top: 80px;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -25%;
  width: 80%;
  height: 150%;
  background: radial-gradient(circle, rgba(62, 146, 204, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -20%;
  width: 60%;
  height: 100%;
  background: radial-gradient(circle, rgba(30, 77, 140, 0.2) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
}

.hero h1 {
  color: var(--white);
  margin-bottom: var(--space-lg);
}

.hero-subtitle {
  font-size: var(--font-size-xl);
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: var(--space-2xl);
  line-height: 1.7;
}

.hero-cta {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

/* ============================================
   CARDS
   ============================================ */
.card {
  background: var(--white);
  border-radius: var(--border-radius-lg);
  padding: var(--space-xl);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
  border: 1px solid rgba(10, 36, 99, 0.05);
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.card-icon {
  width: 64px;
  height: 64px;
  background: var(--gradient-primary);
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-lg);
}

.card-icon svg {
  width: 32px;
  height: 32px;
  color: var(--white);
}

.card h3 {
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-md);
}

.card p {
  color: var(--grey);
  margin-bottom: 0;
}

/* Service Card */
.service-card {
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--gradient-primary);
  transform: scaleY(0);
  transition: transform var(--transition-base);
}

.service-card:hover::before {
  transform: scaleY(1);
}

/* ============================================
   TECHNOLOGIES / LOGOS
   ============================================ */
.tech-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-2xl);
  padding: var(--space-xl) 0;
}

.tech-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-lg);
  background: var(--white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
  min-width: 140px;
}

.tech-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.tech-item span {
  font-weight: 600;
  color: var(--primary);
  font-size: var(--font-size-sm);
  text-align: center;
}

.tech-icon {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--grey-light);
  border-radius: var(--border-radius);
  font-weight: 700;
  color: var(--primary);
  font-size: var(--font-size-lg);
}

/* ============================================
   WHY CHOOSE US
   ============================================ */
.feature-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-xl);
}

@media (max-width: 768px) {
  .feature-list {
    grid-template-columns: 1fr;
  }
}

.feature-item {
  display: flex;
  gap: var(--space-lg);
  padding: var(--space-lg);
  background: var(--white);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.feature-item:hover {
  box-shadow: var(--shadow-md);
}

.feature-icon {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  background: rgba(62, 146, 204, 0.1);
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

.feature-content h4 {
  color: var(--primary);
  margin-bottom: var(--space-sm);
}

.feature-content p {
  color: var(--grey);
  margin: 0;
  font-size: var(--font-size-sm);
}

/* ============================================
   INDUSTRIES
   ============================================ */
.industry-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--space-lg);
}

.industry-item {
  padding: var(--space-lg);
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--border-radius);
  text-align: center;
  transition: all var(--transition-base);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.industry-item:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-4px);
}

.industry-item svg {
  width: 40px;
  height: 40px;
  margin-bottom: var(--space-md);
  color: var(--accent-light);
}

.industry-item span {
  display: block;
  font-weight: 500;
  font-size: var(--font-size-sm);
}

/* ============================================
   ABOUT PAGE
   ============================================ */
.about-intro {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3xl);
  align-items: center;
}

.about-image {
  position: relative;
  border-radius: var(--border-radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
}

.about-image::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-primary);
  opacity: 0.1;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
  text-align: center;
}

.stat-item {
  padding: var(--space-xl);
}

.stat-number {
  font-size: var(--font-size-4xl);
  font-weight: 700;
  color: var(--accent);
  display: block;
  margin-bottom: var(--space-sm);
}

.stat-label {
  color: rgba(255, 255, 255, 0.8);
  font-size: var(--font-size-sm);
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-xl);
}

.value-card {
  text-align: center;
  padding: var(--space-2xl);
}

.value-card .card-icon {
  margin: 0 auto var(--space-lg);
}

/* ============================================
   SERVICES PAGE
   ============================================ */
.services-intro {
  text-align: center;
  max-width: 800px;
  margin: 0 auto var(--space-3xl);
}

.service-detail {
  padding: var(--space-3xl);
  margin-bottom: var(--space-xl);
  border-radius: var(--border-radius-xl);
}

.service-detail:nth-child(even) {
  background: var(--grey-light);
}

.service-header {
  display: flex;
  align-items: flex-start;
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.service-header .card-icon {
  flex-shrink: 0;
}

.service-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-md);
  margin-top: var(--space-lg);
}

.service-list li {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) 0;
}

.service-list li::before {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: var(--space-3xl);
}

.contact-info {
  padding: var(--space-2xl);
  background: var(--gradient-hero);
  border-radius: var(--border-radius-xl);
  color: var(--white);
}

.contact-info h3 {
  color: var(--white);
  margin-bottom: var(--space-xl);
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.contact-icon {
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-icon svg {
  width: 24px;
  height: 24px;
}

.contact-form {
  padding: var(--space-2xl);
  background: var(--white);
  border-radius: var(--border-radius-xl);
  box-shadow: var(--shadow-lg);
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  font-weight: 500;
  margin-bottom: var(--space-sm);
  color: var(--primary);
}

.form-input,
.form-textarea {
  width: 100%;
  padding: var(--space-md);
  font-family: var(--font-primary);
  font-size: var(--font-size-base);
  border: 2px solid rgba(10, 36, 99, 0.1);
  border-radius: var(--border-radius);
  transition: all var(--transition-fast);
  background: var(--white);
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(62, 146, 204, 0.1);
}

.form-textarea {
  resize: vertical;
  min-height: 150px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--primary-dark);
  color: rgba(255, 255, 255, 0.8);
  padding: var(--space-3xl) 0 var(--space-xl);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}

.footer-brand p {
  margin-top: var(--space-md);
  font-size: var(--font-size-sm);
  line-height: 1.8;
}

.footer h4 {
  color: var(--white);
  font-size: var(--font-size-base);
  margin-bottom: var(--space-lg);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  font-size: var(--font-size-sm);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--white);
}

.footer-bottom {
  padding-top: var(--space-xl);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: var(--font-size-sm);
}

.social-links {
  display: flex;
  gap: var(--space-md);
}

.social-link {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.social-link:hover {
  background: var(--accent);
}

.social-link svg {
  width: 20px;
  height: 20px;
}

/* ============================================
   PAGE HEADERS
   ============================================ */
.page-header {
  background: var(--gradient-hero);
  padding: calc(80px + var(--space-3xl)) 0 var(--space-3xl);
  text-align: center;
  color: var(--white);
}

.page-header h1 {
  color: var(--white);
  margin-bottom: var(--space-md);
}

.page-header p {
  font-size: var(--font-size-lg);
  opacity: 0.9;
  max-width: 600px;
  margin: 0 auto;
}

/* ============================================
   SECTION HEADERS
   ============================================ */
.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto var(--space-3xl);
}

.section-header p {
  color: var(--grey);
  font-size: var(--font-size-lg);
}

.section-label {
  display: inline-block;
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: var(--space-md);
}

/* ============================================
   CTA SECTION
   ============================================ */
.cta-section {
  background: var(--gradient-primary);
  padding: var(--space-3xl) 0;
  text-align: center;
  color: var(--white);
}

.cta-section h2 {
  color: var(--white);
  margin-bottom: var(--space-md);
}

.cta-section p {
  opacity: 0.9;
  margin-bottom: var(--space-xl);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .about-intro {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 80px;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    padding: var(--space-xl);
    box-shadow: var(--shadow-lg);
  }

  .nav-links.active {
    display: flex;
  }

  .mobile-toggle {
    display: flex;
  }

  .hero-cta {
    flex-direction: column;
  }

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

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-bottom {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }

  .service-header {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  :root {
    --space-xl: 1.5rem;
    --space-2xl: 2rem;
    --space-3xl: 2.5rem;
    --space-4xl: 3rem;
  }

  .container {
    padding: 0 var(--space-md);
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */
.mb-0 {
  margin-bottom: 0;
}

.mb-sm {
  margin-bottom: var(--space-sm);
}

.mb-md {
  margin-bottom: var(--space-md);
}

.mb-lg {
  margin-bottom: var(--space-lg);
}

.mb-xl {
  margin-bottom: var(--space-xl);
}

.mb-2xl {
  margin-bottom: var(--space-2xl);
}

.mt-0 {
  margin-top: 0;
}

.mt-lg {
  margin-top: var(--space-lg);
}

.mt-xl {
  margin-top: var(--space-xl);
}

.pt-0 {
  padding-top: 0;
}

.pb-0 {
  padding-bottom: 0;
}

.hidden {
  display: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}