﻿/* PDF Modal with Gallery Styles */
.pdf-modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  animation: fadeIn 0.3s;
}
.pdf-modal-content {
  position: relative;
  margin: 1% auto;
  width: 95%;
  height: 95%;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
}
.pdf-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #ddd;
  background-color: #f8f9fa;
  border-radius: 8px 8px 0 0;
}
.pdf-modal-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #333;
}
.pdf-modal-close {
  background: none;
  border: none;
  font-size: 28px;
  font-weight: bold;
  color: #999;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s;
}
.pdf-modal-close:hover {
  color: #333;
  background-color: #e9ecef;
}
.pdf-modal-body {
  flex: 1;
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.pdf-iframe-container {
  flex: 1;
  position: relative;
  overflow: hidden;
}
.pdf-iframe {
  width: 100%;
  height: 100%;
  border: none;
}
/* PDF Gallery Styles */
.pdf-gallery {
  background-color: #f8f9fa;
  border-top: 1px solid #ddd;
  padding: 15px 20px;
  overflow-x: auto;
  display: flex;
  align-items: center;
  gap: 15px;
  min-height: 120px;
}
.pdf-gallery-title {
  font-size: 14px;
  font-weight: 600;
  color: #666;
  margin: 0;
  padding-right: 15px;
  white-space: nowrap;
  border-right: 1px solid #ddd;
}
.pdf-gallery-items {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 5px 0;
}
.pdf-gallery-item {
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 10px 15px;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 120px;
  text-decoration: none;
  color: #333;
}
.pdf-gallery-item:hover {
  background-color: #0d6efd;
  color: #fff;
  border-color: #0d6efd;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}
.pdf-gallery-item.active {
  background-color: #0d6efd;
  color: #fff;
  border-color: #0d6efd;
}
.pdf-gallery-item i {
  font-size: 24px;
  margin-bottom: 8px;
}
.pdf-gallery-item-title {
  font-size: 12px;
  font-weight: 500;
  text-align: center;
  line-height: 1.3;
  max-width: 100px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
/* Mobile responsiveness */
@media (max-width: 768px) {
  .pdf-modal-content {
    margin: 2% auto;
    width: 98%;
    height: 96%;
  }
  .pdf-modal-header {
    padding: 10px 15px;
  }
  .pdf-modal-title {
    font-size: 16px;
  }
  .pdf-gallery {
    padding: 10px 15px;
    min-height: 100px;
  }
  .pdf-gallery-title {
    font-size: 12px;
    padding-right: 10px;
  }
  .pdf-gallery-item {
    min-width: 100px;
    padding: 8px 12px;
  }
  .pdf-gallery-item i {
    font-size: 20px;
    margin-bottom: 5px;
  }
  .pdf-gallery-item-title {
    font-size: 11px;
  }
}
@media (max-width: 480px) {
  .pdf-modal-content {
    margin: 5px;
    width: calc(100% - 10px);
    height: calc(100% - 10px);
  }
  .pdf-gallery {
    padding: 8px 10px;
    min-height: 80px;
  }
  .pdf-gallery-item {
    min-width: 80px;
    padding: 6px 8px;
  }
}