/* Bookmark cards styling - minimal dark design */

.bookmark-card {
  height: auto;
  min-height: 200px;
  margin-bottom: 15px;
  display: flex;
  flex-direction: column;
  background: #1a1a1a;
  border: 0.5px solid #bbbbbb38; /* lighter grey border for glassy effect */
  box-shadow: 0 4px 24px rgba(200, 200, 200, 0.082), 0 2px 8px rgba(0, 0, 0, 0.18); /* subtle light grey shadow */
  border-radius: 8px;
  overflow: hidden;
  position: relative;
  transition: all 0.3s ease;
  cursor: pointer;
  padding: 0;
  animation: fadeIn 0.5s ease-in-out;
}

.bookmark-card[data-special="true"] {
  min-height: 280px; /* Increased height for more space */
}

.bookmark-card:hover {
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 8px 24px rgba(255, 191, 0, 0.316), 0 2px 8px rgba(0, 0, 0, 0.4);
  border-image: linear-gradient(45deg, #1407c3cc , #ffaa00a7) 1;
  background: linear-gradient(90deg, #1a1a1a 70%, #c38407 100%);
}

.bookmark-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -150%;
  width: 60%;
  height: 220%;
  background: linear-gradient(
    120deg,
    transparent 0%,
    transparent 35%,
    rgba(255, 255, 255, 0.15) 45%,
    rgba(255, 255, 255, 0.25) 52%,
    rgba(255, 255, 255, 0.15) 60%,
    transparent 70%,
    transparent 100%
  );
  z-index: 10;
  opacity: 0;
  transition: all 0.4s ease-out;
  transform: rotate(25deg);
  pointer-events: none;
  mix-blend-mode: overlay;
}

.bookmark-card:hover::before {
  left: 150%;
  opacity: 1;
}



.bookmark-image-container {
  flex-shrink: 0;
  width: 100%;
  height: 67%; /* 2/3 of the card height */
  position: relative;
  overflow: hidden;
  background-color: #0f0f0f;
}

.bookmark-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
  filter: brightness(0.85);
}

.bookmark-card:hover .bookmark-image {
  transform: scale(1.02);
  filter: brightness(1);
}

.bookmark-content {
  flex: 1;
  padding: 15px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  background: #1a1a1a;
}

.bookmark-card:hover .bookmark-content {
  background: linear-gradient(90deg, #232323 80%, #2c1a07 100%);
  transition: background 0.3s ease;
}

/* Special bookmark card styling (Victorian London) */
.bookmark-card[data-special="true"] .bookmark-content {
  position: relative;
  background-image: url('../images/bookmarks/background.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  padding: 25px; /* Increased padding for more space */
  min-height: 130px; /* Ensure minimum height for content */
}

.bookmark-card[data-special="true"] .bookmark-content::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url('../images/bookmarks/castle.png');
  background-size: cover; /* Changed to cover to fill full area */
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.7; /* Reduced opacity for better text visibility */
  filter: blur(1px); /* Added slight blur for text readability */
  pointer-events: none;
  z-index: 1;
  transition: all 0.3s ease;
}

.bookmark-card[data-special="true"] .bookmark-content::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(0, 0, 0, 0.3) 0%,
    rgba(0, 0, 0, 0.4) 30%,
    rgba(0, 0, 0, 0.5) 70%,
    rgba(0, 0, 0, 0.7) 100%
  ); /* Lighter gradient overlay for better text visibility */
  pointer-events: none;
  z-index: 2;
  opacity: 0.9;
}

.bookmark-card[data-special="true"] .bookmark-content > * {
  position: relative;
  z-index: 3;
}

.bookmark-card[data-special="true"]:hover .bookmark-content::before {
  filter: blur(0.5px) brightness(1.1); /* Reduce blur and brighten on hover */
  transform: scale(1.02); /* Subtle scale effect */
}

.bookmark-card[data-special="true"]:hover .bookmark-content::after {
  opacity: 0.6; /* Reduce overlay opacity on hover for better visibility */
}

.bookmark-content h3 {
  margin: 0 0 10px 0;
  color: #ffffff;
  font-size: 1.1em;
  font-weight: 600;
  line-height: 1.3;
}

.bookmark-description {
  margin: 0 0 15px 0;
  color: #cccccc;
  font-size: 0.9em;
  line-height: 1.5;
  flex-grow: 1;
}

.bookmark-meta {
  display: flex;
  flex-direction: row;
  gap: 20px;
  font-size: 0.85em;
  color: #888;
  margin-top: auto;
}

.bookmark-meta .bookmark-location {
  font-weight: 500;
  color: #aaa;
}

.bookmark-meta .bookmark-time {
  color: #aaa;
}

.bookmark-meta .bookmark-period {
  color: #aaa;
}

/* Remove bookmark icon overlay */

/* Responsive design for bookmark cards */
@media (max-width: 768px) {
  .bookmark-card {
    margin-bottom: 12px;
    min-height: 180px;
  }
  
  .bookmark-image-container {
    height: 60%;
  }
  
  .bookmark-content {
    padding: 12px;
  }
  
  .bookmark-content h3 {
    font-size: 1em;
  }
  
  .bookmark-description {
    font-size: 0.85em;
  }
  
  .bookmark-meta {
    font-size: 0.8em;
    flex-direction: column;
    gap: 4px;
  }
}

/* Loading and empty states for bookmark tab */
.bookmark-loading {
  text-align: center;
  padding: 40px 20px;
  color: #888;
}

.bookmark-loading .spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #333;
  border-left-color: #666;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 15px;
}

.no-bookmarks {
  text-align: center;
  padding: 40px 20px;
  color: #888;
  font-style: italic;
}

.no-bookmarks::before {
  content: "📚";
  display: block;
  font-size: 3em;
  margin-bottom: 15px;
  opacity: 0.3;
}

/* Bookmark count display */
.bookmark-count-container {
  margin-bottom: 15px;
  text-align: center;
  color: #888;
  font-size: 0.9em;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

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