/* 
 * CSS Mask - Fancy Reveal Effects
 * This file contains mask reveal animations for image transitions
 */

@property --position {
  syntax: "<percentage>";
  inherits: false;
  initial-value: 0%;
}

@property --position-multi {
  syntax: "<percentage>";
  inherits: false;
  initial-value: 0%;
}

.mask-reveal-section {
  padding: 3rem 0;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  background: linear-gradient(to bottom, rgba(255,255,255,0.95), rgba(255,255,255,0.8));
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  overflow: hidden;
}

.mask-reveal-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    radial-gradient(circle at 20% 30%, rgba(255, 111, 97, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(100, 200, 255, 0.1) 0%, transparent 50%);
  z-index: -1;
}

.mask-reveal-section h1 {
  font-size: 2.8rem;
  line-height: 1.3;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #333;
  background: linear-gradient(90deg, #ff6f61, #ff9a8b);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent; /* Standard property instead of text-fill-color */
  display: inline-block;
  animation: shimmer 2s infinite;
  background-size: 200% 100%;
}

@keyframes shimmer {
  0% {
    background-position: -100% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.mask-reveal-section h2 {
  font-size: 1.4rem;
  line-height: 1.5;
  font-weight: 500;
  margin-bottom: 2.5rem;
  color: #666;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.mask-hero {
  display: grid;
  grid-template-columns: 1fr;
  border-radius: 15px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
  margin: 0 auto 2rem;
  max-width: 85%;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.mask-hero:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

.mask-hero::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 2px solid #ff6f61;
  border-radius: 15px;
  box-sizing: border-box;
  opacity: 0.5;
  pointer-events: none;
}

.mask-slide {
  grid-area: 1 / 1;
  block-size: 70vh;
  max-height: 500px;
  position: relative;
}

.mask-slide img {
  inline-size: 100%;
  block-size: inherit;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.mask-slide:first-child:hover img {
  transform: scale(1.05);
}

/* Mask Effects */
.mask-slide:nth-child(2) {
  /* Default: Circular Reveal */
  mask-image: radial-gradient(circle, #000 var(--position), #0000 0);
  mask-size: 25px 25px;
  transition: --position 0.75s ease-in-out, --position-multi 0.75s ease-in-out;
}

.mask-slide:nth-child(2):hover {
  --position: 100%;
  --position-multi: 51%;
}

/* Effect selector styling */
.mask-effects-selector {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 25px;
  padding: 0 20px;
}

.mask-effect-btn {
  padding: 10px 18px;
  background-color: #f0f0f0;
  color: #333;
  border: none;
  border-radius: 25px;
  cursor: pointer;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.mask-effect-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.mask-effect-btn.active {
  background-color: #ff6f61;
  color: white;
  box-shadow: 0 5px 15px rgba(255, 111, 97, 0.3);
}

/* Hover instructions */
.mask-hero::before {
  content: 'Hover to reveal';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 10px 20px;
  border-radius: 30px;
  font-size: 1rem;
  font-weight: 500;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 10;
  pointer-events: none;
}

.mask-hero:hover::before {
  opacity: 1;
}

/* Responsive adjustments */
@media (max-width: 992px) {
  .mask-hero {
    max-width: 90%;
  }
  
  .mask-slide {
    block-size: 60vh;
    max-height: 450px;
  }
  
  .mask-reveal-section h1 {
    font-size: 2.4rem;
  }
}

@media (max-width: 768px) {
  .mask-hero {
    max-width: 95%;
  }
  
  .mask-slide {
    block-size: 50vh;
    max-height: 400px;
  }
  
  .mask-reveal-section h1 {
    font-size: 2rem;
  }
  
  .mask-reveal-section h2 {
    font-size: 1.1rem;
  }
  
  .mask-effects-selector {
    gap: 8px;
  }
  
  .mask-effect-btn {
    padding: 8px 14px;
    font-size: 0.8rem;
  }
}

@media (max-width: 576px) {
  .mask-slide {
    block-size: 40vh;
    max-height: 300px;
  }
  
  .mask-reveal-section h1 {
    font-size: 1.8rem;
  }
  
  .mask-reveal-section h2 {
    font-size: 1rem;
    margin-bottom: 1.5rem;
  }
}
