/* tv-hero.css — aggressive isolation to defeat template/Bootstrap conflicts */

/* Root isolation */
#home.tvhero-root{
  position: relative !important;
  margin: 0 !important;
  padding: 0 !important;
  background: #000 !important;
  overflow: visible !important;
  z-index: 3 !important; /* sit above particle background */
}

/* If your particle background overlaps, force it behind */
#particle-animation{
  z-index: 0 !important;
  pointer-events: none !important;
}

/* Scroll distance */
#home.tvhero-root .tvhero-scroll-scene{
  position: relative !important;
  height: 220vh !important; /* adjust if you want longer/shorter */
  background: #000 !important;
  overflow: visible !important;
}

/* Sticky stage */
#home.tvhero-root .tvhero-stage{
  position: sticky !important;
  top: 0 !important;
  height: 100vh !important;
  min-height: 100vh !important;
  overflow: hidden !important;
  background: #000 !important;
  z-index: 1 !important;
}

/* Layers */
#home.tvhero-root .tvhero-layer{
  position: absolute !important;
  inset: 0 !important;
  transform-origin: center center !important;
  will-change: transform, opacity, filter !important;
}

/* Video */
#home.tvhero-root .tvhero-video-layer video{
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  display: block !important;
}

/* Image */
#home.tvhero-root .tvhero-image-layer{
  opacity: 0;
}
#home.tvhero-root .tvhero-image-layer img{
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  display: block !important;
}

/* Vignette */
#home.tvhero-root .tvhero-vignette{
  position: absolute !important;
  inset: 0 !important;
  pointer-events: none !important;
  background: radial-gradient(ellipse at center,
    rgba(0,0,0,.10) 0%,
    rgba(0,0,0,.55) 70%,
    rgba(0,0,0,.80) 100%) !important;
  z-index: 2 !important;
}

/* Content overlay */
#home.tvhero-root .tvhero-content{
  position: absolute !important;
  inset: 0 !important;
  z-index: 3 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 24px !important;
  pointer-events: none !important;
}

/* Card */
#home.tvhero-root .tvhero-card{
  pointer-events: none !important;
  max-width: 980px !important;
  margin: 0 auto !important;
  padding: 28px !important;
  border-radius: 18px !important;
  background: rgba(0,0,0,.18) !important;
 /* backdrop-filter: blur(6px) !important;*/
  color: #fff !important;
  box-shadow: 0 20px 60px rgba(0,0,0,.35) !important;
}

/* Typography (avoid template h1/h4 overrides) */
#home.tvhero-root .tvhero-title{
  margin: 0 0 12px !important;
  font-size: clamp(34px, 6vw, 68px) !important;
  line-height: 1.05 !important;
  color: #fff !important;
}

#home.tvhero-root .tvhero-subtitle{
  margin: 0 !important;
  font-size: 18px !important;
  opacity: .95 !important;
  color: #fff !important;
}

#home.tvhero-root .tvhero-text{
  margin: 0 !important;
  font-size: 18px !important;
  opacity: .92 !important;
  color: #fff !important;
}

/* Buttons should still be clickable? If you want buttons clickable, remove pointer-events none on content/card and set it here */
#home.tvhero-root .tvhero-content,
#home.tvhero-root .tvhero-card{
  pointer-events: auto !important;
}

/* Stats layout */
#home.tvhero-root .tvhero-stats{
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}
#home.tvhero-root .tvhero-stat{
  padding: 14px 12px !important;
  border-radius: 14px !important;
  background: rgba(0,0,0,.18) !important;
  border: 1px solid rgba(255,255,255,.08) !important;
}
#home.tvhero-root .tvhero-stat-value{
  font-size: 22px !important;
  font-weight: 700 !important;
}
#home.tvhero-root .tvhero-stat-label{
  font-size: 13px !important;
  opacity: .9 !important;
}

/* Mobile */
@media (max-width: 768px){
  #home.tvhero-root .tvhero-card{ padding: 20px !important; }
  #home.tvhero-root .tvhero-stats{ grid-template-columns: 1fr !important; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce){
  #home.tvhero-root .tvhero-scroll-scene{ height: 100vh !important; }
  #home.tvhero-root .tvhero-image-layer{ opacity: 0 !important; }
}
/* CSS Document */
/* Video 2 starts invisible until scroll crossfade */
#home.tvhero-root .tvhero-video2{
  opacity: 0;
}

.gallery-sidebar{
  background: #fff;
  border: 1px solid #e9eef5;
  border-radius: 16px;
}

.gallery-filter-list{
  display:flex;
  flex-direction:column;
  gap:10px;
  max-height: 520px;
  overflow:auto;
  padding-right: 6px;
}

.cat-btn{
  width:100%;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px;
  padding:10px 12px;
  border-radius: 12px;
  border: 1px solid #e9eef5;
  background: #f7f9fc;
  color:#1f2937;
  transition: .15s ease;
  text-align:left;
}
.cat-btn:hover{ transform: translateY(-1px); }
.cat-btn.active{
  background: rgba(99,102,241,.12);
  border-color: rgba(99,102,241,.35);
}

.cat-name{ font-weight: 600; }
.cat-count{
  font-size: .8rem;
  color:#6b7280;
  background: #fff;
  border: 1px solid #e9eef5;
  padding: 2px 8px;
  border-radius: 999px;
}

.template-card{
  background:#fff;
  border: 1px solid #e9eef5;
  border-radius: 16px;
  overflow:hidden;
  height:100%;
  transition: .15s ease;
}
.template-card:hover{
  transform: translateY(-2px);
  box-shadow: 0 16px 40px rgba(0,0,0,.08);
}

.template-thumb img{
  width:100%;
  height:160px;
  object-fit:cover;
  display:block;
}

.template-body{ padding: 14px; }
.template-tag{
  display:inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(99,102,241,.10);
  color: #4f46e5;
  font-size:.8rem;
  font-weight:600;
}
.template-title{ font-weight:700; margin:10px 0 6px; color:#111827; }
.template-desc{ color:#6b7280; font-size:.92rem; min-height:44px; }
.template-actions{ display:flex; gap:10px; margin-top: 12px; }

/* Make sure the <a> doesn't inherit weird styles */
.template-card, .template-card * { text-decoration: none; }

/* Mobile: sidebar becomes horizontal scroll */
@media (max-width: 991px){
  .gallery-filter-list{
    flex-direction:row;
    max-height:none;
    overflow:auto;
    padding-bottom: 6px;
  }
  .cat-btn{ white-space:nowrap; width:auto; }
}

/* Hero Buttons */
.tvhero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 30px;
}

/* Mobile Fix */
@media (max-width: 768px) {
  .tvhero-buttons {
    flex-direction: column;
    gap: 15px;
  }

  .tvhero-buttons .btn {
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }
}

@media (max-width: 768px) {
  .hero-btn-secondary {
    margin-top: 5px;
  }
}

/* ===========================
   GALLERY FIX (BOOTSTRAP SAFE) - IMPROVED
=========================== */

#gallery {
  overflow-x: hidden; /* prevents mobile sideways scroll due to shadows/gutters */
}

#gallery .gallery-sidebar {
  border-radius: 16px;
  background: rgba(255,255,255,.75);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(0,0,0,.06);
}

/* Sticky sidebar only on desktop */
@media (min-width: 992px) {
  #gallery .gallery-sidebar {
    position: sticky;
    top: 90px;
    max-height: calc(100vh - 120px);
    overflow: auto;
  }
}

/* Category list spacing */
#gallery .gallery-filter-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

#gallery .cat-btn {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  width: 100%;
  border-radius: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(0,0,0,.08);
  background: #fff;
  font-weight: 600;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

#gallery .cat-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 25px rgba(0,0,0,.06);
}

#gallery .cat-btn.active {
  background: rgba(79,70,229,.06);
  border-color: rgba(79,70,229,.30);
  box-shadow: 0 12px 30px rgba(79,70,229,.10);
}

#gallery .cat-count {
  min-width: 28px;
  height: 22px;
  padding: 0 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(0,0,0,.06);
  font-size: 12px;
  font-weight: 700;
}

/* Cards */
#gallery .template-card {
  height: 100%;
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(0,0,0,.06);
  box-shadow: 0 10px 30px rgba(0,0,0,.06);
  transition: transform .2s ease, box-shadow .2s ease;
}

#gallery .template-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 50px rgba(0,0,0,.10);
}

/* ✅ Thumbnail: consistent height (prevents distortion) */
#gallery .template-thumb {
  display: block;
  overflow: hidden;
}

#gallery .template-thumb img {
  width: 100%;
  height: 190px;          /* fixed preview height */
  object-fit: cover;      /* keeps nice crop */
  display: block;
}

/* Body */
#gallery .template-body {
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

#gallery .template-tag {
  display: inline-flex;
  width: max-content;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(79,70,229,.08);
  color: #4f46e5;
  margin-bottom: 10px;
}

#gallery .template-title {
  font-weight: 800;
  font-size: 16px;
  margin-bottom: 6px;
}

#gallery .template-desc {
  opacity: .75;
  font-size: 13px;
  margin-bottom: 14px;
}

/* ✅ Center actions */
#gallery .template-actions {
  margin-top: auto;
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

#gallery .template-actions .btn {
  min-width: 140px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
}

/* ✅ Mobile: move sidebar on top and make categories horizontal pills */
@media (max-width: 991.98px) {

  #gallery aside.col-lg-3 {
    order: -1;
  }

  /* Remove “tall card” feel on mobile */
  #gallery .gallery-sidebar {
    padding: 14px !important;
  }

  /* Make categories scroll horizontally */
  #gallery .gallery-filter-list {
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 8px;
    gap: 10px;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
  }

  /* nicer scrolling */
  #gallery .gallery-filter-list::-webkit-scrollbar {
    height: 6px;
  }

  #gallery .gallery-filter-list::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,.15);
    border-radius: 999px;
  }

  #gallery .cat-btn {
    flex: 0 0 auto;
    min-width: 180px;
    scroll-snap-align: start;
  }

  /* Optional: hide the tip on small screens to reduce height */
  #gallery .gallery-sidebar .mt-4 {
    display: none;
  }
}

/* ✅ Mobile: 1 card per row + full width button */
@media (max-width: 768px) {

  #gallery .template-thumb img {
    height: 210px; /* a bit taller looks better on mobile */
  }

  #gallery .template-actions {
    gap: 10px;
  }

  #gallery .template-actions .btn {
    width: 100%;
    max-width: 340px;
  }
}

/* ===========================
   GALLERY - MODERN SIDEBAR + MOBILE DROPDOWN
=========================== */

#gallery { overflow-x: hidden; }

/* Sidebar glass look */
#gallery .gallery-sidebar{
  border-radius: 18px;
  background: rgba(255,255,255,.70);
  border: 1px solid rgba(79,70,229,.12);
  box-shadow: 0 14px 50px rgba(17,24,39,.08);
  backdrop-filter: blur(12px);
}

/* Desktop sticky and smooth scrolling */
@media (min-width: 992px){

  /* Outer container keeps rounded border */
  #gallery .gallery-sidebar{
    position: sticky;
    top: 92px;
    max-height: calc(100vh - 130px);

    border-radius: 18px;
    overflow: hidden; /* 👈 this clips scrollbar inside rounded border */
  }

  /* Inner scroll container */
  #gallery .gallery-sidebar-inner{
    max-height: calc(100vh - 130px);
    overflow-y: auto;
    padding-right: 6px;
  }

  /* Chrome scrollbar */
  #gallery .gallery-sidebar-inner::-webkit-scrollbar{
    width: 8px;
  }

  #gallery .gallery-sidebar-inner::-webkit-scrollbar-track{
    background: transparent;
  }

  #gallery .gallery-sidebar-inner::-webkit-scrollbar-thumb{
    background: linear-gradient(
      180deg,
      rgba(99,102,241,.55),
      rgba(79,70,229,.55)
    );
    border-radius: 999px;
  }

  /* Firefox */
  #gallery .gallery-sidebar-inner{
    scrollbar-width: thin;
    scrollbar-color: rgba(79,70,229,.55) transparent;
  }
}

/* Category list */
#gallery .gallery-filter-list{
  display:flex;
  flex-direction:column;
  gap:10px;
}

/* Modern category buttons */
#gallery .cat-btn{
  width:100%;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;

  border-radius:14px;
  padding:12px 12px;

  border:1px solid rgba(17,24,39,.06);
  background: rgba(255,255,255,.82);
  box-shadow: 0 8px 20px rgba(17,24,39,.05);

  font-weight: 650;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}

#gallery .cat-btn:hover{
  transform: translateY(-1px);
  box-shadow: 0 12px 34px rgba(17,24,39,.08);
  border-color: rgba(79,70,229,.20);
}

#gallery .cat-btn.active{
  background: rgba(79,70,229,.10);
  border-color: rgba(79,70,229,.32);
  box-shadow: 0 16px 45px rgba(79,70,229,.14);
}

#gallery .cat-count{
  min-width: 30px;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  display:inline-flex;
  justify-content:center;
  align-items:center;
  font-size: 12px;
  font-weight: 750;
  background: rgba(79,70,229,.10);
  color: #4f46e5;
}

/* Mobile dropdown styling */
#gallery .gallery-select{
  border-radius: 14px;
  padding: 12px 14px;
  border: 1px solid rgba(79,70,229,.18);
  background: rgba(255,255,255,.85);
  box-shadow: 0 10px 30px rgba(17,24,39,.06);
}

/* Make mobile spacing cleaner */
@media (max-width: 991.98px){
  #gallery .gallery-sidebar{
    padding: 14px !important;
  }
}

/* ===========================
   GALLERY: BIGGER FILTER + PAGINATION
=========================== */

/* Make sidebar feel more premium */
#gallery .gallery-sidebar {
  border-radius: 18px;
  background: rgba(255,255,255,.70);
  border: 1px solid rgba(79,70,229,.12);
  box-shadow: 0 14px 50px rgba(17,24,39,.08);
  backdrop-filter: blur(12px);
}

/* Outer clips scrollbar radius */
@media (min-width: 992px) {
  #gallery .gallery-sidebar{
    position: sticky;
    top: 92px;
    max-height: calc(100vh - 130px);
    overflow: hidden;
  }

  #gallery .gallery-sidebar-inner{
    max-height: calc(100vh - 130px);
    overflow-y: auto;
    padding-right: 8px;
  }

  /* smooth + not cut */
  #gallery .gallery-sidebar-inner::-webkit-scrollbar { width: 10px; }
  #gallery .gallery-sidebar-inner::-webkit-scrollbar-track {
    background: transparent;
    margin: 10px 0; /* keeps rounded ends visible */
  }
  #gallery .gallery-sidebar-inner::-webkit-scrollbar-thumb {
    background: rgba(79,70,229,.35);
    border-radius: 999px;
    border: 3px solid rgba(255,255,255,.65);
    background-clip: padding-box;
  }
  #gallery .gallery-sidebar-inner:hover::-webkit-scrollbar-thumb {
    background: rgba(79,70,229,.55);
  }

  /* Firefox */
  #gallery .gallery-sidebar-inner{
    scrollbar-width: thin;
    scrollbar-color: rgba(79,70,229,.55) transparent;
  }
}

/* ✅ Bigger, more modern category buttons */
#gallery .gallery-filter-list{
  display:flex;
  flex-direction:column;
  gap:12px;
}

#gallery .cat-btn{
  width:100%;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:14px;

  padding: 14px 14px;              /* bigger */
  border-radius: 16px;              /* more modern */
  border: 1px solid rgba(17,24,39,.06);
  background: rgba(255,255,255,.88);
  box-shadow: 0 10px 30px rgba(17,24,39,.05);

  font-weight: 750;
  font-size: 15px;                  /* bigger text */
  line-height: 1.1;

  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}

#gallery .cat-btn:hover{
  transform: translateY(-1px);
  border-color: rgba(79,70,229,.22);
  box-shadow: 0 14px 40px rgba(17,24,39,.08);
}

#gallery .cat-btn.active{
  background: rgba(79,70,229,.10);
  border-color: rgba(79,70,229,.34);
  box-shadow: 0 18px 55px rgba(79,70,229,.14);
}

#gallery .cat-count{
  min-width: 36px;
  height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-size: 12px;
  font-weight: 800;
  background: rgba(79,70,229,.12);
  color: #4f46e5;
}

/* Mobile dropdown bigger */
#gallery .gallery-select{
  border-radius: 16px;
  padding: 14px 14px;
  font-weight: 650;
  border: 1px solid rgba(79,70,229,.18);
  background: rgba(255,255,255,.90);
  box-shadow: 0 12px 35px rgba(17,24,39,.06);
}

/* Pagination styling */
#gallery .gallery-pagination{
  margin-top: 26px;
  display:flex;
  justify-content:center;
  gap:10px;
  flex-wrap:wrap;
}

#gallery .page-btn{
  border: 1px solid rgba(79,70,229,.18);
  background: rgba(255,255,255,.85);
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 700;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}

#gallery .page-btn:hover{
  transform: translateY(-1px);
  box-shadow: 0 12px 30px rgba(17,24,39,.07);
}

#gallery .page-btn.active{
  background: rgba(79,70,229,.10);
  border-color: rgba(79,70,229,.35);
}

/* ✅ Reduce the "dead area" at bottom */
#gallery .row#gallleryGrid,
#gallery #galleryGrid{
  margin-bottom: 0 !important;
}

#gallery.section{
  padding-bottom: 60px; /* keep nice spacing but not huge */
}

/* ===============================
   GALLERY: SIDEBAR (NO UGLY SCROLL)
================================ */

/* sidebar card stays modern */
#gallery .gallery-sidebar {
  border-radius: 18px;
  background: rgba(255,255,255,.75);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(0,0,0,.06);
  box-shadow: 0 14px 40px rgba(0,0,0,.06);
}

/* ✅ IMPORTANT: remove forced scrollbar */
#gallery .gallery-sidebar-inner {
  overflow: visible;
}

/* Sticky sidebar only on desktop, BUT without scrollbar */
@media (min-width: 992px) {
  #gallery .gallery-sidebar {
    position: sticky;
    top: 90px;
  }
}

/* Category buttons slightly bigger + modern */
#gallery .cat-btn {
  padding: 12px 14px;
  border-radius: 14px;
  font-size: 14px;
}

/* ===============================
   GALLERY: PAGINATION (NUMBERED)
================================ */

#gallery .gallery-pagination-wrap {
  display: flex;
  justify-content: center;
  margin-top: 28px;
}

#gallery .gallery-pagination {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.70);
  border: 1px solid rgba(0,0,0,.06);
  box-shadow: 0 14px 40px rgba(0,0,0,.06);
  backdrop-filter: blur(10px);
}

#gallery .page-btn {
  border: 0;
  background: transparent;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 14px;
  color: rgba(0,0,0,.70);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease, color .2s ease;
}

#gallery .page-btn:hover {
  background: rgba(79,70,229,.08);
  color: #4f46e5;
  transform: translateY(-1px);
}

#gallery .page-btn.active {
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: #fff;
  box-shadow: 0 14px 30px rgba(79,70,229,.18);
}

#gallery .page-btn:disabled {
  opacity: .45;
  cursor: not-allowed;
  transform: none;
}

#gallery .page-ellipsis {
  padding: 0 6px;
  opacity: .55;
  font-weight: 800;
}

/* Mobile: pagination fits small screens */
@media (max-width: 576px) {
  #gallery .gallery-pagination {
    gap: 6px;
    padding: 8px 10px;
  }
  #gallery .page-btn {
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    font-size: 13px;
  }
}


/* ✅ Remove forced sidebar scrollbar */
#gallery .gallery-sidebar-inner{
  overflow: visible !important;
}

/* Keep sticky behavior without scrollbar */
@media (min-width: 992px){
  #gallery .gallery-sidebar{
    position: sticky;
    top: 90px;
  }
}

#gallery .gallery-pagination-wrap{
  display:flex;
  justify-content:center;
  margin-top:28px;
}

#gallery .gallery-pagination{
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding:10px 12px;
  border-radius:999px;
  background: rgba(255,255,255,.70);
  border:1px solid rgba(0,0,0,.06);
  box-shadow: 0 14px 40px rgba(0,0,0,.06);
  backdrop-filter: blur(10px);
}

#gallery .page-btn{
  border:0;
  background:transparent;
  min-width:40px;
  height:40px;
  padding:0 12px;
  border-radius:999px;
  font-weight:700;
  font-size:14px;
  color:rgba(0,0,0,.70);
  display:inline-flex;
  align-items:center;
  justify-content:center;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease, color .2s ease;
}

#gallery .page-btn:hover{
  background: rgba(79,70,229,.08);
  color:#4f46e5;
  transform: translateY(-1px);
}

#gallery .page-btn.active{
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color:#fff;
  box-shadow: 0 14px 30px rgba(79,70,229,.18);
}

#gallery .page-btn:disabled{
  opacity:.45;
  cursor:not-allowed;
  transform:none;
}

#gallery .page-ellipsis{
  padding:0 6px;
  opacity:.55;
  font-weight:800;
}


#contact .section-title,
#contact .section-subtitle,
#contact .section-title span {
color: rgba(255,255,255,0.95);}

