/* --- WebsiteCard.css --- */

/* 3D Perspective Container */
.website-card-container {
  aspect-ratio: 4 / 3; 
  width: 100%;
  perspective: 1000px;
  position: relative;
}

/* The Card Itself */
.browser-window {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.2s ease-out;
  will-change: transform;
  
  border-radius: 0.75rem;
  background-color: #0f172a; /* slate-900 */
  border: 1px solid #1e293b; /* slate-800 */
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Browser Header/Toolbar */
.browser-header {
  height: 2rem;
  flex-shrink: 0;
  background-color: #1e293b; /* slate-800 */
  border-top-left-radius: 0.75rem;
  border-top-right-radius: 0.75rem;
  display: flex;
  align-items: center;
  padding: 0 1rem;
  gap: 0.5rem;
  border-bottom: 1px solid #334155; /* slate-700 */
  position: relative;
  z-index: 50; /* Always on top of everything */
}

/* Traffic Light Dots */
.dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
}

.dot.red { background-color: rgba(239, 68, 68, 0.9); }
.dot.amber { background-color: rgba(245, 158, 11, 0.9); }
.dot.green { background-color: rgba(34, 197, 94, 0.9); }

/* Fake Address Bar */
.address-bar {
  margin-left: 1rem;
  height: 0.75rem;
  background-color: rgba(15, 23, 42, 0.5);
  border-radius: 9999px;
  width: 100%;
  max-width: 120px;
}

/* Main Content Area */
.content-area {
  position: relative;
  flex-grow: 1;
  background-color: #020617; /* slate-950 */
  overflow: hidden;
  width: 100%;
}

/* --- LAYERING --- */

/* Layer 1: Background Image (Bottom) */
.bg-image-container {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1; 
}

.bg-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.9;
  transition: transform 700ms;
  display: block;
}

.website-card-container:hover .bg-image {
  transform: scale(1.1);
}

.image-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(1, 16, 25, 0.022); /* Almost transparent default */
  transition: background-color 500ms;
}

.website-card-container:hover .image-overlay {
  background-color: rgba(1, 16, 25, 0.15); /* Very subtle darkening on hover */
}

/* Layer 2: Text Content (Middle - HIGH Z-INDEX) */
.text-overlay {
  position: absolute;
  inset: 0;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  /* Extremely light gradient, barely there but keeps text readable */
  background: linear-gradient(to top, rgba(1, 16, 25, 0.3) 0%, rgba(1, 16, 25, 0.1) 20%, transparent 100%);
  z-index: 20; 
  pointer-events: none; 
}

.text-content-wrapper {
  transform: translateY(0.5rem);
  transition: transform 500ms;
  text-align: left;
  position: relative;
  z-index: 21;
}

.website-card-container:hover .text-content-wrapper {
  transform: translateY(0);
}

.card-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
  margin: 0 0 0.5rem 0;
  text-shadow: 0 4px 12px rgba(0,0,0,0.9); /* Stronger shadow to compensate for lighter background */
  display: block;
}

.card-paragraph {
  color: #e2e8f0; /* slate-200 */
  font-size: 0.9rem;
  line-height: 1.5;
  margin: 0;
  text-shadow: 0 2px 4px rgba(0,0,0,0.9);
  
  opacity: 0; 
  transition: opacity 500ms ease;
  transition-delay: 50ms;
}

.website-card-container:hover .card-paragraph {
  opacity: 1;
}

/* Layer 3: Glare Effect (Top of content, below header) */
.glare-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  /* Blue glare color (#0c93e2) */
  background: radial-gradient(circle at var(--glare-x) var(--glare-y), rgba(12, 147, 226, 0.241) 0%, rgba(12, 147, 226, 0) 25%);
  mix-blend-mode: screen; 
  z-index: 30; 
  transition: opacity 0.3s ease;
  opacity: 0.02; /* Minimal visibility */
}
