/**
 * Image Protection Styles
 * 
 * CSS-level protections to prevent image downloads and copying.
 * Works in conjunction with JavaScript handlers.
 */

/* Disable selection and copying of all images */
img {
  /* Prevent text selection on/around images */
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;

  /* Prevent right-click context menu interactions */
  -webkit-touch-callout: none;

  /* Make cursor indicate non-interactive (optional, can be removed if images should appear clickable) */
  /* cursor: not-allowed; */
}

/* Specifically protect protected images */
img[data-protected="true"] {
  /* Additional layer - prevent all interactions */
  pointer-events: auto; /* Keep auto for page functionality, but JS blocks specific actions */
  
  /* Prevent drag handles from appearing */
  -webkit-user-drag: none;
}

/* Prevent download attribute from functioning */
a[download] img,
img[download] {
  pointer-events: none;
}

/* Protect images in figures */
figure img {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -webkit-touch-callout: none;
}

/* Protect images in links */
a img {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -webkit-touch-callout: none;
}

/* Protect background images - prevent right-click */
div[style*="background-image"],
section[style*="background-image"],
header[style*="background-image"] {
  -webkit-touch-callout: none;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

/* Prevent inspector element selection (partial - JS handles more) */
img::selection {
  background: transparent;
}

img::-moz-selection {
  background: transparent;
}

/* Prevent text around images from being selected with images */
.gallery img,
.image-container img,
.carousel-image,
.slide-image,
.project-header-image img,
.thumbnail img {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -webkit-touch-callout: none;
  pointer-events: auto; /* Allow clicks for navigation, but prevent downloads */
}

/* Disable long-press context menu on mobile */
@media (hover: none) and (pointer: coarse) {
  img {
    -webkit-touch-callout: none;
  }
}

/* Print prevention - hide images when printing if desired */
/* Uncomment if you want to prevent printing images */
/*
@media print {
  img {
    display: none;
  }
}
*/

/* Cursor feedback */
img[data-protected="true"] {
  cursor: default;
}
