/* =============================================
   Ragonezzi Seguros - Custom Styles
   ============================================= */

/* CSS Custom Properties */
:root {
  --primary: #ee731d;
  --primary-dark: #d4650f;
  --primary-light: #f4c7a4;
  --secondary: #f8e6d6;
  --accent: #1e3a5f;
  --accent-light: #2d4a6f;
  --neutral: #f8f9fa;
}

/* Smooth Scrolling */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

/* Selection Color */
::selection {
  background-color: var(--primary);
  color: white;
}

/* Focus Styles for Accessibility */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-dark);
}

/* Animations */
@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

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

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

@keyframes pulse-ring {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  100% {
    transform: scale(1.3);
    opacity: 0;
  }
}

/* Animation Classes */
.animate-float {
  animation: float 3s ease-in-out infinite;
}

.animate-fade-in-up {
  animation: fadeInUp 0.6s ease-out forwards;
}

.animate-fade-in {
  animation: fadeIn 0.6s ease-out forwards;
}

.animate-slide-in-right {
  animation: slideInRight 0.6s ease-out forwards;
}

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

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Header Styles */
#header.scrolled {
  background-color: rgba(255, 255, 255, 0.98);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* Hero Section */
#inicio {
  background-attachment: fixed;
}

/* Service Cards Hover Effect */
.service-card {
  transition: all 0.3s ease;
}

.service-card:hover {
  transform: translateY(-5px);
}

/* Form Styles */
input:focus,
select:focus,
textarea:focus {
  box-shadow: 0 0 0 3px rgba(238, 115, 29, 0.1);
}

input::placeholder,
textarea::placeholder {
  color: #9ca3af;
}

/* Button Styles */
.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  transition: all 0.3s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(238, 115, 29, 0.3);
}

/* WhatsApp Float Button Animation */
.whatsapp-float {
  animation: pulse-ring 2s infinite;
}

/* Mobile Menu Animation */
#mobile-menu {
  transition: all 0.3s ease-in-out;
  max-height: 0;
  overflow: hidden;
}

#mobile-menu.open {
  max-height: 500px;
}

/* Stats Counter Animation */
.stat-number {
  display: inline-block;
}

/* Card Hover Effects */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Image Hover Effect */
.img-hover-zoom {
  overflow: hidden;
}

.img-hover-zoom img {
  transition: transform 0.5s ease;
}

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

/* Link Underline Animation */
.link-underline {
  position: relative;
}

.link-underline::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary);
  transition: width 0.3s ease;
}

.link-underline:hover::after {
  width: 100%;
}

/* Icon Rotation on Hover */
.icon-rotate:hover i {
  transform: rotate(15deg);
}

/* Gradient Text */
.gradient-text {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Section Divider */
.section-divider {
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary) 0%, var(--primary-light) 100%);
  border-radius: 2px;
  margin: 0 auto;
}

/* Responsive Typography */
@media (max-width: 640px) {
  html {
    font-size: 14px;
  }
}

/* Print Styles */
@media print {
  header,
  .whatsapp-float,
  #mobile-menu {
    display: none !important;
  }

  body {
    font-size: 12pt;
  }

  a {
    text-decoration: none;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
  :root {
    --primary: #cc5500;
    --accent: #000033;
  }
}

/* Dark Mode Support (optional, for future) */
@media (prefers-color-scheme: dark) {
  /* Add dark mode styles if needed */
}
