/* ==========================================================================
   WebKeyIndia — Our Achievements (.wka), gallery (.wkg), image viewer (.wklb)
   2026-09-16. Markup: home-certificates.php, index-gallery.php, js/wk-lightbox.js.
   Shared section head (.wk-sec__*) lives in css/wk-home.css.
   ========================================================================== */
.wka, .wkg, .wklb {
  --g-ink:    #0E0F12;
  --g-muted:  #6B7080;
  --g-line:   #E4E7EF;
  --g-orange: #FF7A1A;
  --g-grad:   linear-gradient(90deg, #FF7A1A 0%, #F0471E 55%, #E11D2A 100%);
  --g-font:   "Poppins","Segoe UI",Roboto,-apple-system,BlinkMacSystemFont,Arial,sans-serif;
  font-family: var(--g-font);
}
.wka *, .wka *::before, .wka *::after,
.wkg *, .wkg *::before, .wkg *::after,
.wklb *, .wklb *::before, .wklb *::after { box-sizing: border-box; }

.wka .wk-sec__title, .wkg .wk-sec__title {
  margin: 14px 0 10px !important; padding: 0 !important;
  font-family: var(--g-font) !important; font-size: 36px !important; font-weight: 700 !important;
  line-height: 1.2 !important; letter-spacing: -.3px; text-align: center; color: var(--g-ink) !important;
}

/* ==========================================================================
   OUR ACHIEVEMENTS
   ========================================================================== */
#certificatess.wka {
  position: relative; overflow: hidden;
  padding: 88px 0 !important;
  background:
    radial-gradient(760px 360px at 50% 0%, rgba(255,197,61,.14), transparent 62%),
    radial-gradient(700px 360px at 0% 100%, rgba(255,122,26,.12), transparent 62%),
    radial-gradient(700px 360px at 100% 100%, rgba(225,29,42,.12), transparent 62%),
    linear-gradient(180deg, #121318 0%, #0B0C0F 100%) !important;
}
.wka::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .6;
  background-image: radial-gradient(rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 22px 22px;
}
.wka > * { position: relative; }
.wka .wk-eyebrow { background: rgba(255,197,61,.13); color: #FFD27A; }
.wka .wk-sec__title { color: #fff !important; }
.wka .wk-sec__sub { color: #A7ABB4; }

.wka-badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 22px 0 0; padding: 0; list-style: none; }
.wka-badges li {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 15px 7px 7px; border-radius: 999px;
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.10);
  font-size: 13px; font-weight: 500; color: #E6E8EC;
}
.wka-badges i { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: var(--g-grad); color: #fff; font-size: 13px; }
.wka-badges b { color: #fff; font-weight: 700; }

.wka-rail { position: relative; }
.wka-track {
  display: flex; gap: 22px; margin: 0; padding: 12px 4px 30px; list-style: none;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  scrollbar-width: none; -ms-overflow-style: none; overscroll-behavior-x: contain;
}
.wka-track::-webkit-scrollbar { display: none; }
.wka-item { flex: 0 0 calc((100% - 66px) / 4); min-width: 0; scroll-snap-align: start; }

.wka-card {
  position: relative; display: block; padding: 12px 12px 4px; border-radius: 18px;
  background: linear-gradient(165deg, #FFFFFF 0%, #F4F1EA 100%);
  box-shadow: 0 22px 44px -22px rgba(0,0,0,.8);
  text-decoration: none !important;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s ease;
}
.wka-card::before {                  /* gold -> brand border that lights up on hover */
  content: ""; position: absolute; inset: 0; padding: 2px; border-radius: inherit; pointer-events: none;
  background: linear-gradient(135deg, #FFC53D 0%, rgba(255,122,26,.25) 45%, #E11D2A 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity .35s ease;
}
.wka-card__img { position: relative; overflow: hidden; aspect-ratio: 3 / 4; border-radius: 10px; background: #fff; }
.wka-card__img img { display: block; width: 100%; height: 100%; object-fit: contain; transition: transform .5s ease; }
.wka-card__zoom {
  position: absolute; right: 10px; bottom: 10px; width: 40px; height: 40px;
  display: grid; place-items: center; border-radius: 50%;
  background: rgba(14,15,18,.78); color: #fff; font-size: 15px;
  opacity: 0; transform: scale(.7); transition: opacity .25s ease, transform .25s ease;
}
.wka-card__cap { display: flex; align-items: center; gap: 8px; padding: 11px 4px 9px; font-size: 13px; font-weight: 600; color: #1B1D24; }
.wka-card__cap i { color: #E8A317; font-size: 15px; }
@media (hover: hover) {
  .wka-card:hover { transform: translateY(-8px); box-shadow: 0 34px 60px -26px rgba(255,122,26,.45); }
  .wka-card:hover::before { opacity: 1; }
  .wka-card:hover .wka-card__img img { transform: scale(1.04); }
  .wka-card:hover .wka-card__zoom { opacity: 1; transform: none; }
}
.wka-card:focus-visible { outline: 3px solid var(--g-orange); outline-offset: 4px; }
.wka-card:focus-visible .wka-card__zoom { opacity: 1; transform: none; }

.wka-nav { display: flex; align-items: center; justify-content: center; gap: 14px; }
.wka-arrow {
  width: 46px; height: 46px; display: grid; place-items: center; padding: 0;
  border-radius: 50%; border: 1px solid rgba(255,255,255,.16); background: rgba(255,255,255,.05);
  color: #fff; font-size: 15px; cursor: pointer;
  transition: background .2s, border-color .2s, transform .2s;
}
.wka-arrow:hover { background: var(--g-grad); border-color: transparent; }
.wka-arrow:active { transform: scale(.94); }
.wka-arrow:focus-visible { outline: 3px solid rgba(255,122,26,.6); outline-offset: 3px; }
.wka-btn, .wkg-more {
  display: inline-flex; align-items: center; gap: 10px; height: 48px; padding: 0 26px; border-radius: 999px;
  font-family: var(--g-font); font-size: 14.5px; font-weight: 600; text-decoration: none !important;
  transition: background .2s, border-color .2s, color .2s, transform .2s, box-shadow .2s;
}
.wka-btn { border: 1.5px solid rgba(255,255,255,.28); background: rgba(255,255,255,.04); color: #fff !important; }
.wka-btn i, .wkg-more i { transition: transform .2s; }
.wka-btn:hover, .wkg-more:hover { background: var(--g-grad); border-color: transparent; color: #fff !important; transform: translateY(-2px); box-shadow: 0 14px 30px -10px rgba(225,29,42,.5); }
.wka-btn:hover i, .wkg-more:hover i { transform: translateX(4px); }

/* ==========================================================================
   GALLERY — Life Beyond Technology
   ========================================================================== */
.wkg { position: relative; padding: 88px 0; background: linear-gradient(180deg, #FFFFFF 0%, #F4F6FA 100%); }

.wkg-filters { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0 0 34px; padding: 0; list-style: none; }
.wkg-filter {
  display: inline-flex; align-items: center; gap: 9px; height: 44px; padding: 0 8px 0 18px;
  border-radius: 999px; border: 1.5px solid var(--g-line); background: #fff;
  font-family: var(--g-font); font-size: 14px; font-weight: 600; color: #3F4350;
  text-decoration: none !important; cursor: pointer;
  transition: border-color .2s, color .2s, background .2s, box-shadow .2s, transform .2s;
}
.wkg-filter span {
  min-width: 28px; height: 28px; padding: 0 8px; display: grid; place-items: center;
  border-radius: 999px; background: #F1F3F7; font-size: 12px; color: var(--g-muted);
  transition: background .2s, color .2s;
}
.wkg-filter:hover { border-color: #FFB47A; color: #D9480F; transform: translateY(-1px); }
.wkg-filter:focus-visible { outline: 3px solid rgba(255,122,26,.55); outline-offset: 3px; }
.wkg-filter.is-active { background: var(--g-grad); border-color: transparent; color: #fff; box-shadow: 0 12px 26px -12px rgba(225,29,42,.6); }
.wkg-filter.is-active span { background: rgba(255,255,255,.24); color: #fff; }
.wkg-filter--all { padding-right: 16px; border-style: dashed; }
.wkg-filter--all i { font-size: 12px; }

.wkg-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin: 0; padding: 0; list-style: none; }
.wkg-item { min-width: 0; }
.wkg-item[hidden] { display: none !important; }
.wkg-item.is-in { animation: wkgIn .5s cubic-bezier(.2,.8,.2,1) both; animation-delay: calc(var(--i, 0) * 60ms); }
@keyframes wkgIn { from { opacity: 0; transform: translateY(18px) scale(.97); } to { opacity: 1; transform: none; } }

.wkg-tile {
  position: relative; display: block; overflow: hidden; isolation: isolate;
  aspect-ratio: 4 / 3; border-radius: 18px; background: #E9ECF2;
  box-shadow: 0 18px 40px -24px rgba(14,15,18,.45);
  text-decoration: none !important;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s ease;
}
.wkg-tile img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .7s ease; }
.wkg-tile::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(180deg, rgba(14,15,18,0) 42%, rgba(14,15,18,.86) 100%);
}
.wkg-tile__meta {
  position: absolute; left: 16px; right: 14px; bottom: 14px; z-index: 2;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; color: #fff;
}
.wkg-tile__meta > span { min-width: 0; }
.wkg-tile__meta small {
  display: inline-block; margin-bottom: 6px; padding: 3px 9px; border-radius: 999px;
  background: rgba(255,255,255,.18); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  font-size: 10.5px; font-weight: 600; letter-spacing: .6px; text-transform: uppercase;
}
.wkg-tile__meta b {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  font-size: 15px; font-weight: 600; line-height: 1.35; text-shadow: 0 1px 10px rgba(0,0,0,.45);
}
.wkg-tile__zoom {
  flex: none; width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%;
  background: var(--g-grad); color: #fff; font-size: 15px;
  box-shadow: 0 10px 22px -8px rgba(225,29,42,.7);
  opacity: 0; transform: scale(.5) rotate(-90deg);
  transition: opacity .3s ease, transform .35s cubic-bezier(.2,.9,.3,1.3);
}
@media (hover: hover) {
  .wkg-tile:hover { transform: translateY(-6px); box-shadow: 0 30px 56px -26px rgba(225,29,42,.45); }
  .wkg-tile:hover img { transform: scale(1.08); }
  .wkg-tile:hover .wkg-tile__zoom { opacity: 1; transform: none; }
}
@media (hover: none) { .wkg-tile__zoom { opacity: 1; transform: none; width: 34px; height: 34px; font-size: 13px; } }
.wkg-tile:focus-visible { outline: 3px solid var(--g-orange); outline-offset: 3px; }
.wkg-tile:focus-visible .wkg-tile__zoom { opacity: 1; transform: none; }

.wkg-foot { margin-top: 36px; text-align: center; }
.wkg-more { border: 1.5px solid var(--g-line); background: #fff; color: var(--g-ink) !important; }
.wkg-empty { grid-column: 1 / -1; padding: 40px 0; text-align: center; color: var(--g-muted); }

/* ==========================================================================
   IMAGE VIEWER
   ========================================================================== */
html.wklb-lock, html.wklb-lock body { overflow: hidden !important; }
.wklb {
  position: fixed; inset: 0; z-index: 100010;
  display: grid; grid-template-columns: 84px minmax(0, 1fr) 84px; grid-template-rows: auto minmax(0, 1fr) auto;
  align-items: center; color: #fff;
  background: rgba(8,9,12,.93);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  opacity: 0; transition: opacity .25s ease;
}
.wklb[hidden] { display: none; }
.wklb.is-open { opacity: 1; }
.wklb__top { grid-column: 1 / -1; grid-row: 1; display: flex; align-items: center; justify-content: space-between; padding: 16px 18px 8px; }
.wklb__count { padding: 6px 13px; border-radius: 999px; background: rgba(255,255,255,.08); font-size: 13px; font-weight: 600; letter-spacing: 1px; color: rgba(255,255,255,.8); }
.wklb__close {
  width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%;
  background: rgba(255,255,255,.1); color: #fff; font-family: Arial, sans-serif; font-size: 28px; line-height: 44px;
  cursor: pointer; transition: background .2s, transform .25s;
}
.wklb__close:hover { background: var(--g-grad); transform: rotate(90deg); }
.wklb__nav {
  justify-self: center; width: 54px; height: 54px; padding: 0; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid rgba(255,255,255,.18); background: rgba(255,255,255,.06);
  cursor: pointer; transition: background .2s, border-color .2s, transform .2s;
}
.wklb__nav--prev { grid-column: 1; grid-row: 2; }
.wklb__nav--next { grid-column: 3; grid-row: 2; }
.wklb__nav svg { width: 28px; height: 28px; fill: #fff; }
.wklb__nav:hover { background: var(--g-grad); border-color: transparent; }
.wklb__nav:active { transform: scale(.94); }
.wklb__close:focus-visible, .wklb__nav:focus-visible, .wklb__thumb:focus-visible { outline: 3px solid var(--g-orange); outline-offset: 3px; }
.wklb.is-single .wklb__nav, .wklb.is-single .wklb__thumbs { visibility: hidden; }

.wklb__stage { grid-column: 2; grid-row: 2; height: 100%; min-height: 0; margin: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; }
.wklb__frame { position: relative; display: flex; align-items: center; justify-content: center; width: 100%; min-height: 0; }
.wklb__img {
  display: block; width: auto; height: auto; max-width: 100%;
  max-height: calc(100vh - 230px); max-height: calc(100dvh - 230px);
  object-fit: contain; border-radius: 14px; background: #111;
  box-shadow: 0 30px 80px -20px rgba(0,0,0,.85);
  opacity: 0; transform: scale(.96); transition: opacity .35s ease, transform .35s ease;
}
.wklb__img.is-in { opacity: 1; transform: none; }
.wklb__spin {
  position: absolute; width: 42px; height: 42px; border-radius: 50%;
  border: 3px solid rgba(255,255,255,.15); border-top-color: var(--g-orange);
  animation: wklbSpin .8s linear infinite; opacity: 0; pointer-events: none;
}
.wklb.is-loading .wklb__spin { opacity: 1; }
@keyframes wklbSpin { to { transform: rotate(360deg); } }
.wklb__cap { max-width: min(760px, 92%); text-align: center; font-size: 15px; font-weight: 500; line-height: 1.45; color: #fff; }
.wklb__cap[hidden] { display: none; }
.wklb__thumbs {
  grid-column: 1 / -1; grid-row: 3; display: flex; gap: 8px; justify-content: safe center;
  overflow-x: auto; padding: 12px 18px 20px; scrollbar-width: none;
}
.wklb__thumbs::-webkit-scrollbar { display: none; }
.wklb__thumb {
  flex: none; width: 66px; height: 50px; padding: 0; overflow: hidden;
  border: 2px solid transparent; border-radius: 9px; background: #1c1d22;
  opacity: .5; cursor: pointer; transition: opacity .2s, border-color .2s, transform .2s;
}
.wklb__thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.wklb__thumb:hover { opacity: .9; }
.wklb__thumb.is-active { opacity: 1; border-color: var(--g-orange); transform: translateY(-2px); }

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1199px) {
  .wka-item { flex-basis: calc((100% - 44px) / 3); }
}
@media (max-width: 991px) {
  #certificatess.wka, .wkg { padding: 64px 0 !important; }
  .wka .wk-sec__title, .wkg .wk-sec__title { font-size: 30px !important; }
  .wkg-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
}
@media (max-width: 767px) {
  .wka-item { flex-basis: calc((100% - 16px) / 2); }
  .wka-track { gap: 16px; }
  .wklb { grid-template-columns: 0 minmax(0, 1fr) 0; }
  .wklb__nav { position: absolute; top: 50%; width: 44px; height: 44px; margin-top: -40px; background: rgba(14,15,18,.6); }
  .wklb__nav--prev { left: 10px; }
  .wklb__nav--next { right: 10px; }
  .wklb__stage { padding: 0 12px; }
  .wklb__img { border-radius: 10px; max-height: calc(100vh - 200px); max-height: calc(100dvh - 200px); }
  .wklb__thumb { width: 52px; height: 40px; }
}
@media (max-width: 575px) {
  #certificatess.wka, .wkg { padding: 48px 0 !important; }
  .wka .wk-sec__title, .wkg .wk-sec__title { font-size: 25px !important; }
  .wka-badges li { font-size: 12px; padding-right: 12px; }
  .wka-badges i { width: 26px; height: 26px; font-size: 12px; }
  .wka-item { flex-basis: 72%; }
  .wka-card { padding: 9px 9px 2px; border-radius: 14px; }
  .wka-card__cap { font-size: 12px; }
  .wkg-filters { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; margin: 0 -16px 24px; padding: 2px 16px 6px; scrollbar-width: none; }
  .wkg-filters::-webkit-scrollbar { display: none; }
  .wkg-filter { flex: none; height: 40px; font-size: 13px; }
  .wkg-grid { gap: 10px; }
  .wkg-tile { border-radius: 12px; }
  .wkg-tile__meta { left: 10px; right: 8px; bottom: 9px; gap: 6px; }
  .wkg-tile__meta small { display: none; }
  .wkg-tile__meta b { font-size: 12px; -webkit-line-clamp: 2; }
  .wkg-tile__zoom { width: 28px; height: 28px; font-size: 11px; }
}
@media (max-width: 359px) {
  .wkg-grid { grid-template-columns: minmax(0, 1fr); }
  .wka-item { flex-basis: 84%; }
}
@media (prefers-reduced-motion: reduce) {
  .wka-track { scroll-behavior: auto; }
  .wka-card, .wka-card__img img, .wkg-tile, .wkg-tile img, .wklb, .wklb__img { transition: none; }
  .wkg-item.is-in { animation: none; }
}
