/* ==========================================================================
   Endodinamika - Estilos Corporativos
   ========================================================================== */

/* Variables CSS */
:root {
  --primary-dark: #0a3d6b;
  --primary: #0d4f8b;
  --primary-light: #1a7fd4;
  --accent: #4da6ff;
  --accent-light: #a8d4ff;
  --secondary: #2ecc71;
  --text-dark: #1a2a3a;
  --text-muted: #5a6a7a;
  --light-bg: #f4f8fc;
  --white: #ffffff;
  --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  --gradient-hero: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
  --shadow-soft: 0 4px 20px rgba(13, 79, 139, 0.15);
  --shadow-medium: 0 8px 30px rgba(13, 79, 139, 0.2);
  --transition: all 0.3s ease;
}

/* Reset y Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', sans-serif;
  color: var(--text-dark);
  line-height: 1.7;
  overflow-x: hidden;
}

/* Tipografía */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  line-height: 1.3;
  color: var(--primary-dark);
}

h1 { font-size: 3rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.25rem; }

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

/* ==========================================================================
   Navbar
   ========================================================================== */
.navbar {
  padding: 1rem 0;
  transition: var(--transition);
  background: transparent;
}

.navbar.scrolled {
  background: var(--white);
  box-shadow: var(--shadow-soft);
  padding: 0.5rem 0;
}

.navbar-brand img {
  height: 50px;
  transition: var(--transition);
}

.navbar.scrolled .navbar-brand img {
  height: 40px;
}

.navbar-nav .nav-link {
  font-weight: 500;
  color: var(--white) !important;
  padding: 0.5rem 1rem !important;
  margin: 0 0.25rem;
  border-radius: 25px;
  transition: var(--transition);
}

.navbar.scrolled .nav-link {
  color: var(--text-dark) !important;
}

.navbar-nav .nav-link:hover {
  background: rgba(255,255,255,0.2);
}

.navbar.scrolled .nav-nav .nav-link:hover {
  background: var(--light-bg);
  color: var(--primary) !important;
}

.btn-login {
  background: var(--white);
  color: var(--primary) !important;
  font-weight: 600;
  padding: 0.5rem 1.5rem !important;
  border-radius: 25px;
  transition: var(--transition);
}

.btn-login:hover {
  background: var(--accent-light);
  transform: translateY(-2px);
}

.navbar.scrolled .btn-login {
  background: var(--gradient-primary);
  color: var(--white) !important;
}

.dropdown-menu {
  border: none;
  border-radius: 12px;
  box-shadow: var(--shadow-medium);
  padding: 0.5rem;
  margin-top: 0.5rem;
}

.dropdown-item {
  border-radius: 8px;
  padding: 0.75rem 1rem;
  font-weight: 500;
  transition: var(--transition);
}

.dropdown-item:hover {
  background: var(--light-bg);
  color: var(--primary);
}

.dropdown-item i {
  margin-right: 0.5rem;
  color: var(--primary-light);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
  background: var(--gradient-hero);
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('https://images.unsplash.com/photo-1551190822-a9333d879b1f?w=1920&q=80') center/cover;
  opacity: 0.15;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -50px;
  left: 0;
  right: 0;
  height: 150px;
  background: var(--white);
  clip-path: ellipse(75% 100% at 50% 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero h1 {
  color: var(--white);
  font-size: 3.5rem;
  margin-bottom: 1.5rem;
  animation: fadeInUp 1s ease;
}

.hero h1 span {
  color: var(--accent-light);
}

.hero p {
  color: rgba(255,255,255,0.9);
  font-size: 1.25rem;
  margin-bottom: 2rem;
  animation: fadeInUp 1s ease 0.2s both;
}

.hero-buttons {
  animation: fadeInUp 1s ease 0.4s both;
}

.hero-image {
  position: relative;
  z-index: 2;
  animation: fadeInRight 1s ease 0.3s both;
}

.hero-image img {
  border-radius: 20px;
  box-shadow: var(--shadow-medium);
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn-primary-custom {
  background: var(--gradient-primary);
  border: none;
  color: var(--white);
  padding: 0.875rem 2rem;
  border-radius: 30px;
  font-weight: 600;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(26, 127, 212, 0.4);
}

.btn-primary-custom:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(26, 127, 212, 0.5);
  color: var(--white);
}

.btn-outline-custom {
  background: transparent;
  border: 2px solid var(--white);
  color: var(--white);
  padding: 0.75rem 2rem;
  border-radius: 30px;
  font-weight: 600;
  transition: var(--transition);
}

.btn-outline-custom:hover {
  background: var(--white);
  color: var(--primary);
  transform: translateY(-3px);
}

.btn-secondary-custom {
  background: var(--white);
  border: 2px solid var(--primary);
  color: var(--primary);
  padding: 0.75rem 2rem;
  border-radius: 30px;
  font-weight: 600;
  transition: var(--transition);
}

.btn-secondary-custom:hover {
  background: var(--primary);
  color: var(--white);
  transform: translateY(-3px);
}

/* ==========================================================================
   Sections
   ========================================================================== */
section {
  padding: 6rem 0;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-header h2 {
  position: relative;
  display: inline-block;
  margin-bottom: 1rem;
}

.section-header h2::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: var(--gradient-primary);
  border-radius: 2px;
}

.section-header p {
  font-size: 1.125rem;
  max-width: 600px;
  margin: 1.5rem auto 0;
}

/* ==========================================================================
   Services Section
   ========================================================================== */
.services {
  background: var(--light-bg);
}

.service-card {
  background: var(--white);
  border-radius: 20px;
  padding: 2.5rem 2rem;
  text-align: center;
  transition: var(--transition);
  height: 100%;
  border: 1px solid transparent;
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-medium);
  border-color: var(--accent-light);
}

.service-icon {
  width: 80px;
  height: 80px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  transition: var(--transition);
}

.service-card:hover .service-icon {
  transform: scale(1.1) rotate(5deg);
}

.service-icon i {
  font-size: 2rem;
  color: var(--white);
}

.service-card h4 {
  margin-bottom: 1rem;
  color: var(--primary);
}

.service-card p {
  font-size: 0.95rem;
}

/* ==========================================================================
   About Section
   ========================================================================== */
.about-image {
  position: relative;
}

.about-image img {
  border-radius: 20px;
  box-shadow: var(--shadow-medium);
}

.about-image::before {
  content: '';
  position: absolute;
  top: -20px;
  left: -20px;
  right: 20px;
  bottom: 20px;
  border: 3px solid var(--primary-light);
  border-radius: 20px;
  z-index: -1;
}

.about-content h2 {
  margin-bottom: 1.5rem;
}

.about-content h2 span {
  color: var(--primary-light);
}

.about-list {
  list-style: none;
  padding: 0;
  margin: 2rem 0;
}

.about-list li {
  display: flex;
  align-items: flex-start;
  margin-bottom: 1rem;
  padding: 1rem;
  background: var(--light-bg);
  border-radius: 12px;
  transition: var(--transition);
}

.about-list li:hover {
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.about-list li i {
  color: var(--primary-light);
  font-size: 1.25rem;
  margin-right: 1rem;
  margin-top: 0.25rem;
}

.about-list li span {
  font-weight: 500;
  color: var(--text-dark);
}

/* ==========================================================================
   Stats Section
   ========================================================================== */
.stats {
  background: var(--gradient-hero);
  position: relative;
  overflow: hidden;
}

.stats::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('https://images.unsplash.com/photo-1579684385127-1ef15d508118?w=1920&q=80') center/cover;
  opacity: 0.1;
}

.stat-item {
  text-align: center;
  padding: 2rem;
  position: relative;
  z-index: 2;
}

.stat-number {
  font-family: 'Montserrat', sans-serif;
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.stat-label {
  color: var(--accent-light);
  font-size: 1.125rem;
  font-weight: 500;
}

/* ==========================================================================
   Process Section
   ========================================================================== */
.process-step {
  text-align: center;
  padding: 2rem 1rem;
  position: relative;
}

.process-step::after {
  content: '';
  position: absolute;
  top: 60px;
  right: -50%;
  width: 100%;
  height: 3px;
  background: var(--accent-light);
  z-index: 0;
}

.process-step:last-child::after {
  display: none;
}

.step-number {
  width: 80px;
  height: 80px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  position: relative;
  z-index: 1;
  transition: var(--transition);
}

.step-number span {
  font-family: 'Montserrat', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--white);
}

.process-step:hover .step-number {
  transform: scale(1.1);
  box-shadow: 0 10px 30px rgba(26, 127, 212, 0.4);
}

.process-step h4 {
  color: var(--primary);
  margin-bottom: 0.75rem;
}

/* ==========================================================================
   Equipment Section
   ========================================================================== */
.equipment {
  background: var(--light-bg);
}

.equipment-card {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  transition: var(--transition);
  height: 100%;
}

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

.equipment-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: var(--transition);
}

.equipment-card:hover img {
  transform: scale(1.05);
}

.equipment-card-body {
  padding: 1.5rem;
}

.equipment-card h5 {
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.equipment-card p {
  font-size: 0.9rem;
  margin-bottom: 0;
}

/* ==========================================================================
   CTA Section
   ========================================================================== */
.cta {
  background: var(--gradient-hero);
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -25%;
  width: 600px;
  height: 600px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
}

.cta::after {
  content: '';
  position: absolute;
  bottom: -50%;
  left: -25%;
  width: 500px;
  height: 500px;
  background: rgba(255,255,255,0.03);
  border-radius: 50%;
}

.cta-content {
  position: relative;
  z-index: 2;
  text-align: center;
}

.cta h2 {
  color: var(--white);
  margin-bottom: 1rem;
}

.cta p {
  color: rgba(255,255,255,0.9);
  font-size: 1.125rem;
  margin-bottom: 2rem;
}

/* ==========================================================================
   Contact Section
   ========================================================================== */
.contact-info-card {
  background: var(--white);
  border-radius: 16px;
  padding: 2rem;
  height: 100%;
  box-shadow: var(--shadow-soft);
  transition: var(--transition);
}

.contact-info-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-medium);
}

.contact-icon {
  width: 60px;
  height: 60px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.contact-icon i {
  font-size: 1.5rem;
  color: var(--white);
}

.contact-info-card h5 {
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.contact-form {
  background: var(--white);
  border-radius: 20px;
  padding: 3rem;
  box-shadow: var(--shadow-medium);
}

.form-control {
  border: 2px solid var(--light-bg);
  border-radius: 12px;
  padding: 0.875rem 1.25rem;
  font-size: 1rem;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--primary-light);
  box-shadow: 0 0 0 4px rgba(26, 127, 212, 0.1);
}

.form-label {
  font-weight: 500;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
footer {
  background: var(--primary-dark);
  color: var(--white);
  padding: 4rem 0 0;
}

.footer-logo img {
  height: 50px;
  margin-bottom: 1rem;
}

.footer-text {
  color: rgba(255,255,255,0.7);
  font-size: 0.95rem;
}

.footer-title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 1.125rem;
  margin-bottom: 1.5rem;
  color: var(--white);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--accent-light);
  padding-left: 5px;
}

.footer-links a i {
  margin-right: 0.5rem;
}

.social-links {
  display: flex;
  gap: 1rem;
}

.social-links a {
  width: 45px;
  height: 45px;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  transition: var(--transition);
}

.social-links a:hover {
  background: var(--primary-light);
  transform: translateY(-3px);
}

.footer-bottom {
  background: rgba(0,0,0,0.2);
  padding: 1.5rem 0;
  margin-top: 3rem;
  text-align: center;
}

.footer-bottom p {
  color: rgba(255,255,255,0.6);
  margin: 0;
  font-size: 0.9rem;
}

/* ==========================================================================
   Animations
   ========================================================================== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Scroll animations */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.animated {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 991px) {
  .hero h1 {
    font-size: 2.5rem;
  }
  
  .hero-image {
    margin-top: 3rem;
  }
  
  .navbar-collapse {
    background: var(--white);
    padding: 1rem;
    border-radius: 12px;
    margin-top: 1rem;
    box-shadow: var(--shadow-medium);
  }
  
  .navbar-nav .nav-link {
    color: var(--text-dark) !important;
  }
  
  .process-step::after {
    display: none;
  }
  
  h1 { font-size: 2.5rem; }
  h2 { font-size: 2rem; }
  
  section {
    padding: 4rem 0;
  }
}

@media (max-width: 767px) {
  .hero {
    min-height: auto;
    padding: 8rem 0 6rem;
  }
  
  .hero h1 {
    font-size: 2rem;
  }
  
  .stat-number {
    font-size: 2.5rem;
  }
  
  .about-image::before {
    display: none;
  }
  
  .contact-form {
    padding: 2rem;
  }
}

/* ==========================================================================
   Utilities
   ========================================================================== */
.text-primary-custom {
  color: var(--primary) !important;
}

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

.bg-light-custom {
  background: var(--light-bg) !important;
}

.rounded-custom {
  border-radius: 20px !important;
}

.shadow-custom {
  box-shadow: var(--shadow-soft) !important;
}
