/* ==========================================================================
   MST Automation And Systems - Base Styles
   Theme: Industrial Dark Mode (Charcoal, Orange, Electric Blue)
   ========================================================================== */

:root {
  --color-bg: #0f1115;
  --color-surface: #1a1d24;
  --color-surface-light: #252a34;
  --color-primary: #FF6B00;
  /* Industrial Orange */
  --color-accent: #00E5FF;
  /* Electric Blue */
  --color-text: #e2e8f0;
  --color-text-muted: #94a3b8;

  --font-primary: 'Inter', sans-serif;
  --font-heading: 'Outfit', sans-serif;

  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --glass-bg: rgba(26, 29, 36, 0.7);
  --glass-border: rgba(255, 255, 255, 0.1);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-smooth);
}

/* ==========================================================================
   Layout Containers
   ========================================================================== */

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.text-center {
  text-align: center;
}

.text-accent {
  color: var(--color-accent);
}

/* ==========================================================================
   Typography
   ========================================================================== */

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 3rem;
  text-align: center;
  background: linear-gradient(90deg, #fff, var(--color-text-muted));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn-primary,
.btn-primary-sm {
  display: inline-block;
  background-color: var(--color-primary);
  color: #000;
  font-weight: 600;
  border-radius: 4px;
  transition: var(--transition-smooth);
  border: 1px solid var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-primary {
  padding: 1rem 2rem;
  font-size: 1rem;
}

.btn-primary-sm {
  padding: 0.5rem 1.25rem;
  font-size: 0.875rem;
}

.btn-primary:hover,
.btn-primary-sm:hover {
  background-color: transparent;
  color: var(--color-primary);
  box-shadow: 0 0 15px rgba(255, 107, 0, 0.4);
}

.btn-secondary {
  display: inline-block;
  background-color: transparent;
  color: var(--color-text);
  border: 1px solid var(--glass-border);
  padding: 1rem 2rem;
  font-weight: 600;
  border-radius: 4px;
  transition: var(--transition-smooth);
}

.btn-secondary:hover {
  border-color: var(--color-text);
  background-color: rgba(255, 255, 255, 0.05);
}

/* ==========================================================================
   Navigation
   ========================================================================== */

.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--glass-border);
  transition: var(--transition-smooth);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 2rem;
}

.logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.logo img {
  background-color: rgba(255, 255, 255, 0.95);
  padding: 4px 8px;
  border-radius: 4px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.logo-mst {
  color: var(--color-primary);
}

.logo-auto {
  color: var(--color-text);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links a:not([class^="btn"]) {
  font-weight: 500;
  color: var(--color-text-muted);
}

.nav-links a:not([class^="btn"]):hover {
  color: var(--color-accent);
}

/* Hamburger Menu Base */
.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
  z-index: 1001;
}

.hamburger .bar {
  width: 25px;
  height: 3px;
  background-color: var(--color-text);
  border-radius: 3px;
  transition: all 0.3s ease;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 8rem 2rem 4rem;
  position: relative;
  background: radial-gradient(circle at top right, rgba(0, 229, 255, 0.1), transparent 40%),
    radial-gradient(circle at bottom left, rgba(255, 107, 0, 0.05), transparent 40%);
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  z-index: -1;
  opacity: 0.5;
}

.hero-content {
  text-align: center;
  max-width: 800px;
  margin-bottom: 4rem;
  animation: fadeUp 1s ease-out;
}

.hero h1 {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  letter-spacing: -1px;
}

.hero p {
  font-size: 1.25rem;
  color: var(--color-text-muted);
  margin-bottom: 2.5rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

.hero-stats {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeUp 1s ease-out 0.2s both;
}

.stat-card {
  background: var(--color-surface);
  border: 1px solid var(--glass-border);
  padding: 1.5rem 2.5rem;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 200px;
  backdrop-filter: blur(5px);
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  font-family: var(--font-heading);
  color: var(--color-accent);
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--color-text-muted);
}

/* ==========================================================================
   Services Grid
   ========================================================================== */

.services {
  padding: 6rem 0;
  background-color: var(--color-bg);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.service-card {
  background: var(--color-surface);
  border: 1px solid var(--glass-border);
  padding: 2.5rem;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(255, 107, 0, 0.1) 0%, transparent 100%);
  z-index: -1;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.service-card:hover {
  transform: translateY(-5px);
  border-color: rgba(255, 107, 0, 0.3);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.service-card:hover::before {
  opacity: 1;
}

.service-icon {
  font-size: 3rem;
  margin-bottom: 1.5rem;
}

.service-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.service-card p {
  color: var(--color-text-muted);
  margin-bottom: 2rem;
  flex-grow: 1;
}

.learn-more {
  color: var(--color-accent);
  font-weight: 600;
  font-size: 0.875rem;
  margin-top: auto;
  display: inline-flex;
  align-items: center;
}

/* ==========================================================================
   CTA Section
   ========================================================================== */

.cta-section {
  padding: 6rem 0;
  background: linear-gradient(to right, var(--color-surface), #12141a);
  border-top: 1px solid var(--glass-border);
  border-bottom: 1px solid var(--glass-border);
}

.cta-section h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.cta-section p {
  color: var(--color-text-muted);
  font-size: 1.125rem;
  margin-bottom: 2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ==========================================================================
   Footer
   ========================================================================== */

footer {
  background-color: var(--color-bg);
  padding: 4rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-brand h3 {
  font-size: 1.5rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.footer-brand p {
  color: var(--color-text-muted);
  max-width: 300px;
}

.footer-links h4,
.footer-contact h4 {
  font-size: 1.125rem;
  margin-bottom: 1.5rem;
  color: #fff;
}

.footer-links a {
  display: block;
  color: var(--color-text-muted);
  margin-bottom: 0.75rem;
}

.footer-links a:hover {
  color: var(--color-accent);
  padding-left: 5px;
}

.footer-contact p {
  color: var(--color-text-muted);
  margin-bottom: 0.75rem;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--glass-border);
  color: #64748b;
  font-size: 0.875rem;
}

/* ==========================================================================
   WhatsApp Floating Button
   ========================================================================== */

.whatsapp-float {
  position: fixed;
  width: 60px;
  height: 60px;
  bottom: 40px;
  right: 40px;
  background-color: #25d366;
  color: #000;
  border-radius: 50px;
  text-align: center;
  font-size: 30px;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
}

.whatsapp-float:hover {
  background-color: #1ebe57;
  transform: scale(1.1);
  color: #000;
  box-shadow: 0 0 20px rgba(37, 211, 102, 0.6);
}

/* ==========================================================================
   Forms
   ========================================================================== */

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--color-text-muted);
  font-weight: 500;
}

.form-control {
  width: 100%;
  padding: 1rem;
  background: rgba(15, 17, 21, 0.5);
  border: 1px solid var(--glass-border);
  color: var(--color-text);
  border-radius: 4px;
  font-family: var(--font-primary);
  font-size: 1rem;
  transition: var(--transition-smooth);
}

.form-control:focus {
  outline: none;
  border-color: var(--color-primary);
  background: rgba(15, 17, 21, 0.8);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

/* ==========================================================================
   Animations
   ========================================================================== */

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }

  .hero-actions {
    flex-direction: column;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 250px;
    height: 100vh;
    background-color: rgba(15, 17, 21, 0.98);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: right 0.3s ease;
    z-index: 1000;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.5);
  }

  .nav-links.active {
    right: 0;
  }

  .hamburger {
    display: flex;
  }

  .hamburger.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .hamburger.active .bar:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }
}