/* CSS Animations for a Modern Minimalist Website */

/* 
How to Use:

1. Include this CSS file in your HTML:
   <link rel="stylesheet" href="path/to/your/animations.css">

2. Apply the desired classes to your HTML elements.

Examples:

- To add a scale-up effect to an image on hover:
  <div class="image-hover-scale">
    <img src="path/to/your/image.jpg" alt="Description">
  </div>

- To add a background color change effect to a button on hover:
  <div class="button-hover-bg">
    <button>Click Me</button>
  </div>

- To add a slide-in-left animation to a headline:
  <div class="headline-slide-in-left">
    <h1>Your Headline Here</h1>
  </div>

- To add a spin animation to an SVG icon:
  <div class="icon-spin">
    <svg>...your SVG content...</svg>
  </div>

Feel free to combine these classes with your own styles for more customization.
*/

/* General Transition for Smooth Effect */
* {
  transition: all 0.3s ease;
}

/* Hover Effects */

/* Scale Up Image on Hover */
.image-hover-scale img {
  transition: transform 0.3s ease;
}

.image-hover-scale img:hover {
  transform: scale(1.1);
}

/* Fade In Image on Hover */
.image-hover-fade img {
  transition: opacity 0.3s ease;
}

.image-hover-fade img:hover {
  opacity: 0.7;
}

/* Button Hover Effects */

/* Background Color Change on Hover */
.button-hover-bg button {
  background-color: #008cba;
  color: white;
  border: none;
  padding: 10px 20px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.button-hover-bg button:hover {
  background-color: #005f5f;
}

/* Button Grow on Hover */
.button-hover-grow button {
  transition: transform 0.3s ease;
}

.button-hover-grow button:hover {
  transform: scale(1.1);
}

.div-hover-grow * {
  transition: transform 0.3s ease;
}

.div-hover-grow *:hover {
  transform: scale(1.1);
}

.div-hover-grow *:last-child:focus,
.div-hover-grow *:last-child:hover {
  box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24);
  border-radius: 20px;
  padding: 3rem;
}

/* Keyframe Animations */

/* Pulse Animation for Buttons */
@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

.button-pulse button {
  animation: pulse 2s infinite;
}

/* Slide In Left for Headlines */
@keyframes slide-in-left {
  0% {
    transform: translateX(-100%);
    opacity: 0;
  }
  100% {
    transform: translateX(0);
    opacity: 1;
  }
}

.headline-slide-in-left h1 {
  animation: slide-in-left 0.5s forwards;
}

.headline-hover-scale h1,
.headline-hover-scale h2 {
  transition: transform 0.3s ease;
}

.headline-hover-scale h1:hover,
.headline-hover-scale h2:hover {
  transform: scale(1.1);
}

.headline-pulse h1,
.headline-pulse h2,
.headline-pulse h3,
.headline-pulse h4,
.headline-pulse h5,
.headline-pulse h6,
.headline-pulse p {
    animation: pulse 2s infinite;
  }

/* Fade In for Headlines */
@keyframes fade-in {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

.headline-fade-in h1 {
  animation: fade-in 1s forwards;
}

.text-fade-loop {
  animation: fade-in 3s alternate-reverse infinite;
}

/* Spin Animation for SVG Icons */
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.icon-spin svg {
  animation: spin 2s linear infinite;
}

/* Bounce Animation for Icons */
@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-30px);
  }
  60% {
    transform: translateY(-15px);
  }
}

.icon-bounce svg {
  animation: bounce 2s infinite;
}
