/* ===========================
   Base / Resets / Variables
   =========================== */
:root{
  --primary-color:#2563eb;
  --primary-dark:#1d4ed8;
  --secondary-color:#64748b;
  --accent-color:#f59e0b;
  --success-color:#10b981;
  --background-color:#ffffff;
  --surface-color:#f8fafc;
  --text-primary:#1e293b;
  --text-secondary:#64748b;
  --border-color:#e2e8f0;
  --shadow-sm:0 1px 2px rgba(0,0,0,.05);
  --shadow-md:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -1px rgba(0,0,0,.06);
  --shadow-lg:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -2px rgba(0,0,0,.05);
}

*{margin:0;padding:0;box-sizing:border-box;}
html,body{height:100%;}
img{max-width:100%;display:block;}
body{
  font-family:system-ui,-apple-system,'Segoe UI',Roboto,sans-serif;
  line-height:1.6;
  margin:0;
  background:#f8f9fa;
  color:#333;
}

/* ===========================
   Layout / Container
   =========================== */
.container{
  max-width:1400px;
  margin:0 auto;
  background:#fff;
  padding:40px;
  border-radius:12px;
  box-shadow:0 4px 20px rgba(0,0,0,.1);
}

/* ===========================
   Headings
   =========================== */
.page-title{
  text-align:center;
  font-size:2.5rem;
  font-weight:700;
  color:#2c3e50;
  margin-bottom:10px;
  text-shadow:1px 1px 2px rgba(0,0,0,.1);
}
.page-subtitle{
  text-align:center;
  font-size:1.2rem;
  color:#7f8c8d;
  margin-bottom:40px;
  font-weight:300;
}

/* ===========================
   SEO Content Block
   =========================== */
.seo-content{
  background:#f8f9fa;
  padding:20px;
  border-radius:8px;
  margin-bottom:30px;
  border-left:4px solid #3498db;
}
.seo-content h2{color:#2c3e50;margin-top:0;}
.seo-content p{margin-bottom:15px;text-align:justify;}

/* ===========================
   Year Navigation
   =========================== */
.year-navigation{
  text-align:center;
  margin:30px 0;
  padding:20px;
  background:var(--surface-color);
  border-radius:12px;
  border:1px solid var(--border-color);
}
.year-navigation h3{
  margin-bottom:15px;
  color:var(--text-primary);
  font-weight:700;
}
.year-navigation a{
  color:var(--primary-color);
  text-decoration:none;
  margin:0 8px;
  padding:8px 16px;
  border-radius:8px;
  transition:all .3s ease;
  display:inline-block;
  font-weight:600;
}
.year-navigation a:hover{
  background:var(--primary-color);
  color:#fff;
  transform:translateY(-2px);
  box-shadow:var(--shadow-md);
}
.current-year{
  font-weight:700;
  color:#fff;
  background:var(--primary-color);
  padding:8px 16px;
  border-radius:8px;
  margin:0 8px;
  display:inline-block;
  box-shadow:var(--shadow-md);
}

/* ===========================
   Stats Banner
   =========================== */
.stats{
  text-align:center;
  margin:30px 0;
  padding:25px;
  background:linear-gradient(135deg,var(--success-color),#059669);
  color:#fff;
  border-radius:12px;
  box-shadow:var(--shadow-lg);
}
.stats h3{font-size:2.5rem;font-weight:900;margin-bottom:.5rem;}
.stats p{font-size:1.1rem;opacity:.9;}

/* ===========================
   Manufacturer List
   =========================== */
.manufacturer-list{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(200px,1fr));
  gap:15px;
  margin:20px 0;
}
.manufacturer-item{
  background:#fff;
  padding:15px;
  border-radius:6px;
  box-shadow:0 2px 8px rgba(0,0,0,.1);
  text-align:center;
}

/* ===========================
   Gallery (vpcd only)
   =========================== */
.vpcd-gallery{
  display:grid;
  grid-template-columns:repeat(6,1fr);
  gap:20px;
  justify-items:center;
  margin:30px 0;
}

/* Responsive columns */
@media (max-width:1200px){ .vpcd-gallery{grid-template-columns:repeat(4,1fr);} }
@media (max-width:900px){  .vpcd-gallery{grid-template-columns:repeat(3,1fr);} }
@media (max-width:600px){
  .vpcd-gallery{grid-template-columns:repeat(2,1fr);}
  .page-title{font-size:2rem;}
}
@media (max-width:400px){ .vpcd-gallery{grid-template-columns:1fr;} }

/* ===========================
   Gallery Items / Cards
   =========================== */
.gallery-item{
  display:flex;flex-direction:column;align-items:center;text-align:center;width:100%;
  border:1px solid var(--border-color);
  border-radius:12px;
  overflow:hidden;
  background:#fff;
  box-shadow:var(--shadow-md);
  transition:all .3s ease;
  position:relative;
  cursor:pointer;
}
.gallery-item:hover{
  transform:translateY(-5px);
  box-shadow:var(--shadow-lg);
  border-color:var(--primary-color);
}

/* Label */
.gallery-item-label{
  background:var(--primary-color);
  color:#fff;
  padding:15px;
  font-weight:700;
  text-align:center;
  font-size:15px;
  position:relative;
  line-height:1.3;
  min-height:60px;
  display:flex;
  align-items:center;
  justify-content:center;
  border:0;
}
.gallery-item-label::after{
  content:'';
  position:absolute;
  bottom:-10px;left:50%;transform:translateX(-50%);
  width:0;height:0;
  border-left:10px solid transparent;
  border-right:10px solid transparent;
  border-top:10px solid var(--primary-color);
}
.gallery-item:hover .gallery-item-label{
  background:var(--primary-dark); color:#fff;
}
.gallery-item:hover .gallery-item-label::after{
  border-top-color:var(--primary-dark);
}

/* Thumbnails */
.vpcd-gallery img{
  width:100%;height:auto;
  border-radius:8px;
  transition:transform .3s ease, box-shadow .3s ease;
  cursor:zoom-in;
  opacity:0;animation:fadeIn .5s ease-in-out forwards;
}
.gallery-item:hover img{
  transform:translateY(-3px) scale(1.02);
  box-shadow:0 8px 25px rgba(0,0,0,.25);
}

/* Hover helper overlay (non-blocking) */
.gallery-item::before{
  content:'🔍 Click to enlarge';
  position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);
  background:rgba(0,0,0,.8);color:#fff;padding:10px 20px;border-radius:20px;
  opacity:0;transition:opacity .3s ease;z-index:10; font-size:14px;font-weight:600;
  pointer-events:none; /* do not block clicks/buttons */
}
.gallery-item:hover::before{opacity:1;}

/* “Open in new tab” button (pair with JS that injects it) */
.open-tab-btn{
  position:absolute;bottom:12px;right:12px;
  padding:8px 10px;border-radius:10px;background:rgba(0,0,0,.75);
  color:#fff;text-decoration:none;font-weight:600;font-size:.85rem;
  box-shadow:0 6px 20px rgba(0,0,0,.3);z-index:20;
  opacity:0;transform:translateY(4px);transition:opacity .2s, transform .2s;
}
.gallery-item:hover .open-tab-btn{opacity:1;transform:none;}
@media (hover:none){ .open-tab-btn{opacity:1;transform:none;} }

/* Image fade-in animation */
@keyframes fadeIn{
  from{opacity:0;transform:translateY(20px);}
  to{opacity:1;transform:translateY(0);}
}

/* ===========================
   Lightbox
   =========================== */
.lb-overlay{
  position:fixed;inset:0;background:rgba(0,0,0,.9);
  display:none;align-items:center;justify-content:center;z-index:10000;
}
.lb-overlay.show{display:flex;}

.lb-stage{
  position:relative;max-width:92vw;max-height:92vh;
}
.lb-stage img{
  display:block;max-width:92vw;max-height:92vh;object-fit:contain;
  border-radius:6px;box-shadow:0 10px 40px rgba(0,0,0,.6);
}

/* Counter (top-left) */
.lb-count{
  position:fixed;top:12px;left:12px;background:rgba(0,0,0,.7);color:#fff;
  padding:8px 12px;border-radius:8px;font:14px/1 system-ui,-apple-system,Segoe UI,Roboto,sans-serif;
}

/* Close (top-right) */
.lb-close{
  position:fixed;top:10px;right:10px;width:42px;height:42px;border:0;border-radius:50%;
  background:rgba(255,0,0,.7);color:#fff;font-size:28px;line-height:42px;text-align:center;
  cursor:pointer;transition:background .3s ease;
}

/* Prev/Next arrows */
.lb-nav{
  position:fixed;top:50%;transform:translateY(-50%);
  width:66px;height:66px;border:0;border-radius:50%;
  background:#fff;color:#2c3e50;font-size:40px;line-height:30px;text-align:center;
  cursor:pointer;user-select:none;transition:background .3s ease;
}
.lb-prev{left:40px;}
.lb-next{right:40px;}

/* Caption */
.lb-caption{
  position:fixed;left:12px;bottom:12px;color:#fff;background:rgba(0,0,0,.1);
  border-radius:10px;padding:12px 15px;max-width:70vw;
}
.lb-caption .lb-title{display:block;font-weight:700;margin-bottom:4px;font-size:1.1rem;}
.lb-caption .lb-alt{display:block;opacity:.95;font-size:.95rem;}

/* Hover/Focus states */
.lb-close:hover,.lb-nav:hover{ background:#53e005; }
.lb-close:focus,.lb-nav:focus{ outline:2px solid #fff3; outline-offset:2px; }

/* ===========================
   Scroll-to-top Button
   =========================== */
#myBtn{
  position:fixed;bottom:2rem;right:2rem;width:50px;height:50px;
  background:#2563eb;color:#fff;border:none;border-radius:50%;
  cursor:pointer;z-index:1000;opacity:0;visibility:hidden;transition:all .3s ease;
}
#myBtn.visible{opacity:1;visibility:visible;}

/* ===========================
   Responsive Tweaks
   =========================== */
@media (max-width:768px){
  .container{margin:1rem;padding:15px;}
  .page-title{font-size:2rem;}
  .page-subtitle{font-size:1rem;}
  .stats h3{font-size:2rem;}
  .year-navigation{padding:15px;}
  .year-navigation a,.current-year{margin:3px;padding:6px 12px;font-size:14px;}
}
@media (max-width:480px){
  .page-title{font-size:1.8rem;}
  .year-navigation a,.current-year{display:block;margin:5px 0;}
}

/* ===========================
   Reduced Motion Preference
   =========================== */
@media (prefers-reduced-motion:reduce){
  *{animation-duration:.01ms !important;animation-iteration-count:1 !important;
    transition-duration:.01ms !important;scroll-behavior:auto !important;}
}
