/* Home page: Achievements and Gallery (2026-11-03). Data from the database (achievement_slide, gallery_image);
   managed on /manage/media by Admin, SubAdmin and Faculty. Script: /js/home-media.js (carousel, reveal, lightbox).
   Prefixes: kha- achievements, kgl- gallery, kmx- shared (lightbox, buttons). Colours: css/site-chrome.css tokens. */

.kha, .kgl, .kab, .krc, .krc-scope, .kwt, .kmx-lightbox {
  --m-navy: var(--kc-navy, #0d2847);
  --m-navy-2: var(--kc-navy-2, #12325a);
  --m-blue: var(--kc-blue, #285690);
  --m-gold: var(--kc-gold, #e0a526);
  --m-ink: var(--kc-ink, #1b2a3d);
  --m-muted: var(--kc-muted, #5d6b80);
  --m-line: var(--kc-line, #e3e8f0);
  --m-ease: var(--kc-ease, cubic-bezier(.2, .7, .2, 1));
  font-family: var(--kc-font, 'Inter', 'Open Sans', system-ui, sans-serif);
  -webkit-font-smoothing: antialiased;
}
.kha *, .kgl *, .kab *, .krc *, .krc-scope *, .kwt *, .kmx-lightbox * { box-sizing: border-box; }
/* the old home page CSS zooms every linked image on hover; these sections have their own effects */
.kha a:hover img, .kgl a:hover img, .kab a:hover img, .krc a:hover img, .krc-scope a:hover img { box-shadow: none; }
.kha a:hover img, .kgl a:hover img { transform: none; }

/* ---------- shared bits ---------- */
.kmx-eyebrow { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 10px; font-size: 12.5px; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase; }
.kmx-eyebrow::before { content: ""; width: 26px; height: 2px; border-radius: 2px; background: currentColor; }
.kmx-title { margin: 0; font-family: inherit !important; font-size: clamp(28px, 3.4vw, 40px); font-weight: 700; line-height: 1.1; letter-spacing: -.02em; }
.kmx-lead { margin: 10px 0 0; max-width: 560px; font-size: 15.5px; line-height: 1.6; }
.kmx-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 18px;
  border: 1px solid transparent; border-radius: 999px; font-size: 14px; font-weight: 600; line-height: 1; text-decoration: none !important;
  cursor: pointer; transition: background-color .2s, color .2s, border-color .2s, transform .2s var(--m-ease), box-shadow .2s; }
.kmx-btn:hover { transform: translateY(-1px); }
.kmx-btn:focus-visible, .kmx-round:focus-visible, .kha-card:focus-visible, .kgl-tile:focus-visible { outline: 3px solid var(--m-gold); outline-offset: 3px; }
.kmx-round { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; border-radius: 50%;
  border: 1px solid transparent; font-size: 15px; cursor: pointer; transition: background-color .2s, color .2s, opacity .2s, transform .2s var(--m-ease); }
.kmx-round:disabled { opacity: .35; cursor: default; }
.kmx-del { position: absolute; z-index: 3; top: 10px; right: 10px; display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px;
  border-radius: 999px; background: rgba(180, 35, 24, .92); color: #fff !important; font-size: 12px; font-weight: 600; text-decoration: none !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .25); transition: background-color .2s, transform .2s; }
/* always visible (2026-11-03): it is shown only to users who may delete the item (Admin, SubAdmin, the uploader) */
.kmx-del:hover { background: #8f1c13; transform: translateY(-1px); }

/* reveal on scroll (js adds .is-in; without js everything is visible) */
.kmx-js .kmx-reveal { opacity: 0; transform: translateY(26px); }
.kmx-js .kmx-reveal.is-in { opacity: 1; transform: none; transition: opacity .7s var(--m-ease), transform .7s var(--m-ease); transition-delay: var(--d, 0s); }

/* ---------- Achievements ---------- */
.kha { position: relative; isolation: isolate; overflow: hidden; margin: 28px 0; padding: 64px 0 56px; color: #fff;
  background: linear-gradient(135deg, #0a1f3d 0%, var(--m-navy) 45%, #163a68 100%); }
.kha-aurora { position: absolute; inset: -30%; z-index: -1; pointer-events: none; opacity: .75;
  background:
    radial-gradient(38% 42% at 18% 28%, rgba(224, 165, 38, .30), transparent 70%),
    radial-gradient(34% 40% at 82% 22%, rgba(64, 132, 214, .40), transparent 70%),
    radial-gradient(40% 46% at 62% 88%, rgba(40, 86, 144, .55), transparent 70%);
  animation: kha-drift 22s ease-in-out infinite alternate; }
.kha::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .5;
  background-image: radial-gradient(rgba(255, 255, 255, .09) 1px, transparent 1px); background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 85%); mask-image: linear-gradient(180deg, #000, transparent 85%); }
@keyframes kha-drift { 0% { transform: translate3d(0, 0, 0) rotate(0deg); } 100% { transform: translate3d(4%, -3%, 0) rotate(8deg); } }
.kha-inner { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.kha-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 18px 28px; margin-bottom: 30px; }
.kha .kmx-eyebrow { color: var(--m-gold); }
.kha .kmx-title { color: #fff; }
.kha .kmx-title span { background: linear-gradient(90deg, #ffd47a, var(--m-gold) 45%, #ffe7b0 90%); background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent; animation: kha-shine 6s linear infinite; }
@keyframes kha-shine { to { background-position: -200% 0; } }
.kha .kmx-lead { color: rgba(255, 255, 255, .78); }
.kha-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.kha-count { margin-right: 6px; color: rgba(255, 255, 255, .7); font-size: 13.5px; }
.kha-count b { color: #fff; font-size: 22px; font-weight: 700; margin-right: 4px; font-variant-numeric: tabular-nums; }
.kha .kmx-round { background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .22); color: #fff; }
.kha .kmx-round:not(:disabled):hover { background: var(--m-gold); border-color: var(--m-gold); color: var(--m-navy); }
.kha-add { background: var(--m-gold); color: var(--m-navy) !important; }
.kha-add:hover { background: #f2bd4a; box-shadow: 0 8px 22px rgba(224, 165, 38, .35); }
.kha-manage { border-color: rgba(255, 255, 255, .35); color: #fff !important; }
.kha-manage:hover { background: rgba(255, 255, 255, .12); }

.kha-track { display: flex; gap: 22px; margin: 0 calc((100% - 100vw) / 2); padding: 8px max(24px, calc((100vw - 100%) / 2)) 26px; overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-padding: 0 max(24px, calc((100vw - 100%) / 2)); scrollbar-width: none; -webkit-overflow-scrolling: touch; list-style: none; }
.kha-track::-webkit-scrollbar { display: none; }
.kha-item { flex: 0 0 calc((100% - 3 * 22px) / 3.25); min-width: 0; scroll-snap-align: start; }
@media (max-width: 1100px) { .kha-item { flex-basis: calc((100% - 2 * 22px) / 2.3); } }
@media (max-width: 767px) {
  .kha { padding: 48px 0 40px; }
  .kha-inner { padding: 0 16px; }
  /* phones: one card in the middle, the neighbours peek in equally on both sides */
  .kha-track { margin: 0 -16px; padding: 6px 10vw 22px; gap: 14px; scroll-padding: 0; }
  .kha-item { flex-basis: 80vw; scroll-snap-align: center; }
  .kha-head { margin-bottom: 22px; }
}
/* which device shows which achievement: 0 = laptops, 1 = phones, 2 = both (if a device has none, it shows all) */
@media (min-width: 768px) { .kha:not(.kha--all-desktop) .kha-item[data-view="mobile"] { display: none; } }
@media (max-width: 767px) { .kha:not(.kha--all-mobile) .kha-item[data-view="desktop"] { display: none; } }

.kha-card { position: relative; display: flex; flex-direction: column; height: 100%; overflow: hidden; border-radius: 20px;
  background: #fff; color: var(--m-ink); box-shadow: 0 18px 40px rgba(3, 12, 28, .35); cursor: pointer;
  transition: transform .45s var(--m-ease), box-shadow .45s var(--m-ease); }
.kha-card::before { content: ""; position: absolute; inset: 0; z-index: 2; border-radius: inherit; pointer-events: none;
  box-shadow: inset 0 0 0 2px transparent; transition: box-shadow .35s; }
.kha-card:hover { transform: translateY(-8px); box-shadow: 0 28px 60px rgba(3, 12, 28, .5); }
.kha-card:hover::before { box-shadow: inset 0 0 0 2px var(--m-gold); }
.kha-media { position: relative; display: block; aspect-ratio: 4 / 3.4; overflow: hidden; background: #0e223f; }
.kha-backdrop { position: absolute; inset: -20px; background-size: cover; background-position: center; filter: blur(22px) saturate(1.15) brightness(.8);
  transform: scale(1.1); }
/* height !important: css/style.css forces img{height:auto !important} on small screens */
.kha-media img { position: relative; z-index: 1; display: block; width: 100%; height: 100% !important; max-width: none; object-fit: contain;
  transition: transform .9s var(--m-ease); }
.kha-card:hover .kha-media img { transform: scale(1.05); }
.kha-media::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, transparent 60%, rgba(7, 20, 40, .45)); }
.kha-chip { position: absolute; z-index: 2; left: 12px; top: 12px; display: inline-flex; align-items: center; gap: 6px; max-width: calc(100% - 24px);
  padding: 5px 11px; border-radius: 999px; background: rgba(13, 40, 71, .78); color: #fff; font-size: 11.5px; font-weight: 700; letter-spacing: .06em;
  text-transform: uppercase; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kha-chip i { color: var(--m-gold); }
.kha-zoom { position: absolute; z-index: 2; right: 12px; bottom: 12px; display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 50%; background: rgba(255, 255, 255, .92); color: var(--m-navy); font-size: 13px;
  opacity: 0; transform: scale(.7); transition: opacity .3s, transform .3s var(--m-ease); }
.kha-card:hover .kha-zoom { opacity: 1; transform: none; }
.kha-body { position: relative; flex: 1; padding: 18px 20px 20px; }
.kha-body::before { content: ""; position: absolute; top: 0; left: 20px; width: 42px; height: 3px; border-radius: 0 0 3px 3px; background: var(--m-gold);
  transform-origin: left; transition: width .4s var(--m-ease); }
.kha-card:hover .kha-body::before { width: 84px; }
.kha-body h3 { margin: 4px 0 0; font-family: inherit !important; color: var(--m-navy); font-size: 17px; font-weight: 700; line-height: 1.35; overflow-wrap: anywhere; }
.kha-body p { display: -webkit-box; margin: 8px 0 0; color: var(--m-muted); font-size: 14px; line-height: 1.55; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.kha-progress { position: relative; height: 3px; margin-top: 4px; border-radius: 3px; background: rgba(255, 255, 255, .14); overflow: hidden; }
.kha-progress span { position: absolute; inset: 0 auto 0 0; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--m-gold), #ffd47a);
  transition: width .35s var(--m-ease), left .35s var(--m-ease); }
.kha-empty { padding: 34px 24px; border: 1px dashed rgba(255, 255, 255, .35); border-radius: 18px; color: rgba(255, 255, 255, .85); text-align: center; }
.kha-empty i { display: block; margin-bottom: 10px; color: var(--m-gold); font-size: 30px; }

/* ---------- Gallery ---------- */
.kgl { position: relative; margin: 28px 0; padding: 60px 0 58px; background: linear-gradient(180deg, #fff 0%, #f4f6fa 100%); color: var(--m-ink); }
.kgl-inner { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.kgl-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 18px 28px; margin-bottom: 28px; }
.kgl .kmx-eyebrow { color: var(--m-blue); }
.kgl .kmx-title { color: var(--m-navy); }
.kgl .kmx-lead { color: var(--m-muted); }
.kgl-tools { display: flex; flex-wrap: wrap; gap: 10px; }
.kgl-all { background: var(--m-navy); color: #fff !important; }
.kgl-all:hover { background: var(--m-blue); box-shadow: 0 10px 24px rgba(13, 40, 71, .25); }
.kgl-all i { transition: transform .25s var(--m-ease); }
.kgl-all:hover i { transform: translateX(3px); }
.kgl-add { border-color: #c9d4e4; background: #fff; color: var(--m-navy) !important; }
.kgl-add:hover { border-color: var(--m-blue); }

/* uniform tiles (2026-11-03): every photo in the same 4:3 frame (cropped to fill, the viewer shows the whole photo),
   3 per row (9 = 3 x 3), 2 per row on tablets and phones; an incomplete last row is centred */
.kgl-grid { --kgl-gap: 18px; --kgl-cols: 3; display: flex; flex-wrap: wrap; justify-content: center; gap: var(--kgl-gap); margin: 0; padding: 0; list-style: none; }
.kgl-grid > li { position: relative; min-width: 0; flex: 0 0 calc((100% - (var(--kgl-cols) - 1) * var(--kgl-gap)) / var(--kgl-cols)); aspect-ratio: 4 / 3; }
@media (max-width: 760px) { .kgl-grid { --kgl-cols: 2; --kgl-gap: 12px; } }
@media (max-width: 640px) {
  .kgl { padding: 44px 0 42px; }
  .kgl-inner { padding: 0 16px; }
  .kgl-grid { --kgl-gap: 10px; }
}
.kgl-tile { position: relative; display: block; width: 100%; height: 100%; overflow: hidden; border-radius: 18px; background: #dfe6f0;
  box-shadow: 0 10px 26px rgba(13, 40, 71, .12); cursor: zoom-in; isolation: isolate; }
.kgl-tile img { position: absolute; inset: 0; display: block; width: 100%; height: 100% !important; max-width: none; object-fit: cover; transition: transform 1.1s var(--m-ease), filter .6s; }
.kgl-tile:hover img { transform: scale(1.08); filter: saturate(1.1); }
.kgl-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 62%, rgba(7, 20, 40, .78)); opacity: .7; transition: opacity .4s; }
.kgl-tile:hover::after, .kgl-tile:focus-visible::after { opacity: 1; }
.kgl-cap { position: absolute; z-index: 2; left: 16px; right: 16px; bottom: 14px; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px;
  color: #fff; transform: translateY(6px); transition: transform .4s var(--m-ease); }
.kgl-tile:hover .kgl-cap, .kgl-tile:focus-visible .kgl-cap { transform: none; }
.kgl-cap span { font-size: 14.5px; font-weight: 600; line-height: 1.35; text-shadow: 0 1px 6px rgba(0, 0, 0, .35); overflow: hidden; display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.kgl-cap i { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%;
  background: rgba(255, 255, 255, .2); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); font-size: 12px; opacity: 0; transition: opacity .3s; }
.kgl-tile:hover .kgl-cap i { opacity: 1; }
/* gallery reveal: a soft scale-in, one after the other */
.kmx-js .kgl-grid .kmx-reveal { transform: scale(.94); }
.kmx-js .kgl-grid .kmx-reveal.is-in { transform: none; }
/* the editable page text with the old three pictures (shown while no photo has been uploaded) */
.kgl-fallback ul { margin: 0; }
.kgl-fallback img { border-radius: 16px; }

/* ---------- Lightbox ---------- */
.kmx-lightbox { position: fixed; inset: 0; z-index: 9999; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
  padding: 64px 72px 28px; background: rgba(5, 14, 30, .92); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); color: #fff;
  opacity: 0; transition: opacity .25s; }
.kmx-lightbox.is-open { opacity: 1; }
.kmx-lightbox[hidden] { display: none; }
.kmx-lb-figure { display: flex; flex-direction: column; align-items: center; gap: 14px; max-width: 100%; max-height: 100%; margin: 0; min-height: 0; }
.kmx-lb-figure img { display: block; max-width: min(1200px, 100%); max-height: calc(100vh - 210px); width: auto; height: auto; border-radius: 12px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .5); transform: scale(.96); transition: transform .35s var(--m-ease); }
.kmx-lightbox.is-open .kmx-lb-figure img { transform: none; }
.kmx-lb-figure figcaption { max-width: 820px; text-align: center; }
.kmx-lb-figure figcaption strong { display: block; font-size: 17px; font-weight: 700; }
.kmx-lb-figure figcaption span { display: block; margin-top: 6px; color: rgba(255, 255, 255, .78); font-size: 14.5px; line-height: 1.55; }
.kmx-lb-chip { display: inline-block; margin-bottom: 8px; padding: 3px 10px; border-radius: 999px; background: var(--m-gold); color: var(--m-navy);
  font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.kmx-lb-chip:empty { display: none; }
.kmx-lb-count { position: absolute; top: 20px; left: 24px; color: rgba(255, 255, 255, .7); font-size: 14px; font-variant-numeric: tabular-nums; }
.kmx-lightbox .kmx-round { position: absolute; background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .2); color: #fff; }
.kmx-lightbox .kmx-round:hover { background: var(--m-gold); color: var(--m-navy); }
.kmx-lb-close { top: 14px; right: 16px; }
.kmx-lb-prev { left: 16px; top: 50%; margin-top: -22px; }
.kmx-lb-next { right: 16px; top: 50%; margin-top: -22px; }
.kmx-lb-open { position: absolute; top: 14px; right: 72px; display: inline-flex; align-items: center; gap: 6px; height: 44px; padding: 0 14px;
  border-radius: 999px; color: rgba(255, 255, 255, .85) !important; font-size: 13px; text-decoration: none !important; }
.kmx-lb-open:hover { color: #fff !important; background: rgba(255, 255, 255, .1); }
@media (max-width: 640px) {
  .kmx-lightbox { padding: 64px 12px 20px; }
  .kmx-lb-prev, .kmx-lb-next { top: auto; bottom: 18px; margin-top: 0; }
  .kmx-lb-figure img { max-height: calc(100vh - 250px); }
  .kmx-lb-figure figcaption { padding: 0 56px; }
}
html.kmx-locked, html.kmx-locked body { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  .kha-aurora, .kha .kmx-title span { animation: none; }
  .kmx-js .kmx-reveal, .kmx-js .kmx-reveal.is-in { opacity: 1; transform: none; transition: none; }
  .kha-card, .kha-media img, .kgl-tile img, .kgl-cap, .kmx-btn { transition: none; }
  .kha-card:hover, .kha-card:hover .kha-media img, .kgl-tile:hover img { transform: none; }
}

/* ---------- About KEC (2026-11-03, second version) ----------
   The campus photo fills the left half from edge to edge (as before the redesign), the text sits on a warm ivory panel
   with a fine gold dot pattern. Fonts: Playfair Display (heading, drop cap) and Lora (text), loaded in index.jsp. */
.kab { --kab-serif: 'Playfair Display', Georgia, 'Times New Roman', serif; --kab-text: 'Lora', Georgia, serif;
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); background: #fbf6ec; color: #2a2f3a; }
.kab-media { position: relative; min-height: 560px; overflow: hidden; background: #0d2847; }
.kab-photo { position: absolute; inset: 0; }
.kab-photo img { position: absolute; inset: 0; width: 100%; height: 100% !important; max-width: none; object-fit: cover;
  animation: kab-zoom 26s ease-in-out infinite alternate; }
@keyframes kab-zoom { from { transform: scale(1); } to { transform: scale(1.08); } }
.kab-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(13, 40, 71, 0) 55%, rgba(13, 40, 71, .28) 100%),
  linear-gradient(0deg, rgba(13, 40, 71, .55) 0%, rgba(13, 40, 71, 0) 38%); pointer-events: none; }
.kab-badge { position: absolute; left: 32px; bottom: 30px; z-index: 2; display: flex; align-items: center; gap: 14px; color: #fff; }
.kab-badge b { font-family: var(--kab-serif); font-size: 46px; font-weight: 700; line-height: 1; color: #ffd47a; }
.kab-badge span { padding-left: 14px; border-left: 2px solid rgba(255, 212, 122, .7); font-size: 12px; font-weight: 700; letter-spacing: .18em; line-height: 1.5;
  text-transform: uppercase; }
.kab-body { position: relative; padding: 70px clamp(24px, 5vw, 76px) 66px; overflow: hidden;
  background-image: radial-gradient(rgba(201, 138, 18, .16) 1px, transparent 1.3px), linear-gradient(135deg, #fffaf0 0%, #f7eedb 100%);
  background-size: 22px 22px, 100% 100%; }
.kab-body::before { content: ""; position: absolute; top: 0; left: 0; width: 6px; height: 100%; background: linear-gradient(180deg, var(--m-gold), #c98a12 60%, var(--m-navy)); }
.kab-body::after { content: "KEC"; position: absolute; right: -10px; bottom: -40px; font-family: var(--kab-serif); font-size: 220px; font-weight: 700; line-height: 1;
  color: rgba(13, 40, 71, .045); pointer-events: none; }
.kab-body > * { position: relative; z-index: 1; max-width: 660px; }
.kab .kmx-eyebrow { color: #a8740d; letter-spacing: .22em; }
.kab .kmx-title { font-family: var(--kab-serif) !important; color: var(--m-navy); font-size: clamp(36px, 4vw, 54px); font-weight: 700; letter-spacing: -.01em; }
.kab .kmx-title span { font-style: italic; background: linear-gradient(90deg, #c98a12, var(--m-gold)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.kab-body .kmx-title::after { content: ""; display: block; width: 0; height: 3px; margin-top: 16px; background: linear-gradient(90deg, var(--m-gold), transparent);
  transition: width 1.1s .35s var(--m-ease); }
.kab-content.is-in .kmx-title::after, html:not(.kmx-js) .kab-body .kmx-title::after { width: 120px; }
.kab-text { margin-top: 22px; }
.kab-text p { margin: 0 !important; padding: 0 !important; font-family: var(--kab-text); color: #343a46; font-size: 17px; line-height: 1.9;
  text-align: justify; text-justify: inter-word; -webkit-hyphens: auto; hyphens: auto; overflow-wrap: break-word; }
.kab-text p:first-child::first-letter { float: left; margin: 6px 12px 0 0; font-family: var(--kab-serif); font-size: 68px; font-weight: 700; line-height: .8; color: #c98a12; }
.kab-text strong { color: var(--m-navy); font-weight: 700; }
.kab-text a { color: #0d2847 !important; font-family: var(--kc-font, 'Inter', sans-serif); font-size: 15px; font-weight: 700; text-decoration: underline !important;
  text-decoration-thickness: 2px !important; text-underline-offset: 4px; text-decoration-color: var(--m-gold) !important; transition: color .2s; }
.kab-text a:hover { color: #a8740d !important; }
.kab-text a[href="/about/history"]::after { content: " \2192"; }
.kab-facts { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 0; padding: 0; list-style: none; }
.kab-facts li { display: inline-flex; align-items: center; gap: 8px; padding: 8px 15px; border: 1px solid rgba(201, 138, 18, .35); border-radius: 999px;
  background: rgba(255, 255, 255, .75); color: var(--m-navy); font-size: 13.5px; font-weight: 600; transition: transform .25s var(--m-ease), background-color .25s; }
.kab-facts li:hover { transform: translateY(-2px); background: #fff; }
.kab-facts i { color: #c98a12; }
.kab-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 28px; }
.kab-cta { background: var(--m-navy); color: #fff !important; }
.kab-cta:hover { background: #a8740d; box-shadow: 0 10px 24px rgba(13, 40, 71, .2); }
.kab-cta i { transition: transform .25s var(--m-ease); }
.kab-cta:hover i { transform: translateX(4px); }
.kab-link { display: inline-flex; align-items: center; gap: 6px; padding-bottom: 2px; border-bottom: 2px solid var(--m-gold); color: var(--m-navy) !important;
  font-size: 14.5px; font-weight: 700; text-decoration: none !important; transition: color .2s; }
.kab-link:hover { color: #a8740d !important; }
.kab-link i { font-size: 11px; }
@media (max-width: 900px) {
  .kab { grid-template-columns: 1fr; }
  .kab-media { min-height: 0; aspect-ratio: 16 / 10; }
  .kab-body { padding: 44px 20px 48px 26px; }
  .kab-body::after { font-size: 140px; }
  .kab-text p { font-size: 15.5px; line-height: 1.8; word-spacing: -.02em; }
  .kab-text p:first-child::first-letter { font-size: 54px; margin: 5px 10px 0 0; }
  .kab-badge { left: 20px; bottom: 18px; }
  .kab-badge b { font-size: 36px; }
}

/* ---------- Our Recruiting Partners (2026-11-03) ---------- */
.krc { position: relative; padding: 64px 0 62px; background: linear-gradient(180deg, #f4f6fa 0%, #fff 100%); color: var(--m-ink); }
.krc-inner { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.krc-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 18px 28px; margin-bottom: 28px; }
.krc .kmx-eyebrow { color: var(--m-blue); }
.krc .kmx-title { color: var(--m-navy); }
.krc .kmx-lead { color: var(--m-muted); }
.krc-tools { display: flex; flex-wrap: wrap; gap: 10px; }
.krc-more { background: var(--m-navy); color: #fff !important; }
.krc-more:hover { background: var(--m-blue); box-shadow: 0 10px 24px rgba(13, 40, 71, .25); }
.krc-add { border-color: #c9d4e4; background: #fff; color: var(--m-navy) !important; }
.krc-add:hover { border-color: var(--m-blue); }
/* same tile as a gallery photo: 4:3, 3 per row (2 on tablets and phones) */
.krc-viewport { --krc-gap: 18px; --krc-cols: 3; container-type: inline-size; }
.krc-track { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--krc-gap); margin: 0; padding: 0; list-style: none; }
.krc-item { position: relative; flex: 0 0 calc((100cqi - (var(--krc-cols) - 1) * var(--krc-gap)) / var(--krc-cols)); min-width: 0; aspect-ratio: 4 / 3; }
@media (max-width: 760px) { .krc-viewport { --krc-gap: 12px; --krc-cols: 2; } }
@media (max-width: 640px) { .krc { padding: 44px 0 42px; } .krc-inner { padding: 0 16px; } .krc-viewport { --krc-gap: 10px; } }
/* more than three logos: an endless band (the list is there twice), stops under the mouse or keyboard focus */
.krc-viewport.is-moving { overflow: hidden; padding: 8px 0 14px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.krc-viewport.is-moving .krc-track { flex-wrap: nowrap; justify-content: flex-start; gap: 0; width: max-content; animation: krc-scroll var(--krc-dur, 40s) linear infinite; }
.krc-viewport.is-moving .krc-item { margin-right: var(--krc-gap); }
.krc-viewport.is-moving:hover .krc-track, .krc-viewport.is-moving:focus-within .krc-track { animation-play-state: paused; }
@keyframes krc-scroll { to { transform: translateX(-50%); } }
.krc-tile { position: relative; display: flex; flex-direction: column; width: 100%; height: 100%; overflow: hidden; border: 1px solid var(--m-line); border-radius: 18px;
  background: #fff; box-shadow: 0 10px 26px rgba(13, 40, 71, .08); color: var(--m-navy); text-decoration: none !important;
  transition: transform .35s var(--m-ease), box-shadow .35s, border-color .35s; }
.krc-tile::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, var(--m-gold), #ffd47a);
  transform: scaleX(0); transform-origin: left; transition: transform .45s var(--m-ease); }
a.krc-tile:hover, .krc-tile:hover { transform: translateY(-4px); border-color: rgba(224, 165, 38, .55); box-shadow: 0 18px 36px rgba(13, 40, 71, .14); }
.krc-tile:hover::before { transform: none; }
.krc-logo { position: relative; flex: 1; display: flex; align-items: center; justify-content: center; min-height: 0; padding: 9% 12% 4%; }
/* height !important: css/style.css forces img{height:auto !important} on small screens */
.krc-logo img { display: block; width: 100%; height: 100% !important; max-width: none; object-fit: contain; transition: transform .45s var(--m-ease); }
.krc-tile:hover .krc-logo img { transform: scale(1.06); }
.krc-logo img[hidden] { display: none; }
.krc-name { display: block; padding: 0 14px 14px; color: var(--m-muted); font-size: 13.5px; font-weight: 600; text-align: center; white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis; }
.krc-del-form { margin: 0; }
button.kmx-del { border: 0; font-family: inherit; line-height: 1; cursor: pointer; }
.krc-empty { padding: 34px 24px; border: 1px dashed #c9d4e4; border-radius: 18px; color: var(--m-muted); text-align: center; }
.krc-empty i { display: block; margin-bottom: 10px; color: var(--m-gold); font-size: 30px; }
.krc-scope .kmx-del { position: absolute; z-index: 3; top: 10px; right: 10px; }
.krc-scope .krc-tile { height: auto; aspect-ratio: 4 / 3; }

/* ---------- KEC Web Team (2026-11-03): jsp/category/webteamswiper.jsp, home page and /category/kecwebteam ---------- */
.kwt { position: relative; overflow: hidden; padding: 78px 0 84px; color: #e8eef7;
  background: radial-gradient(rgba(255, 255, 255, .06) 1px, transparent 1.4px) 0 0 / 26px 26px, linear-gradient(160deg, #0a1a33 0%, #0d2847 55%, #10325c 100%); }
.kwt-glow { position: absolute; inset: auto -10% -40% auto; width: 620px; height: 620px; border-radius: 50%;
  background: radial-gradient(circle, rgba(224, 165, 38, .22), transparent 65%); filter: blur(10px); animation: kwt-drift 14s ease-in-out infinite alternate; pointer-events: none; }
.kwt::before { content: ""; position: absolute; left: -12%; top: -30%; width: 560px; height: 560px; border-radius: 50%;
  background: radial-gradient(circle, rgba(64, 132, 214, .22), transparent 65%); pointer-events: none; }
@keyframes kwt-drift { to { transform: translate(-60px, -40px) scale(1.08); } }
.kwt-inner { position: relative; z-index: 1; width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.kwt-head { max-width: 720px; margin: 0 auto 40px; text-align: center; }
.kwt .kmx-eyebrow { color: #ffd47a; }
.kwt .kmx-eyebrow::after { content: ""; width: 26px; height: 2px; border-radius: 2px; background: currentColor; }
.kwt .kmx-title { color: #fff; }
.kwt .kmx-title span { background: linear-gradient(90deg, #ffd47a, var(--m-gold)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.kwt .kmx-lead { margin-left: auto; margin-right: auto; color: rgba(232, 238, 247, .78); }
/* the two leads */
.kwt-leads { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.kwt-lead { position: relative; display: flex; align-items: center; gap: 24px; padding: 24px; border: 1px solid rgba(255, 255, 255, .12); border-radius: 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, .09), rgba(255, 255, 255, .03)); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, .22); transition: transform .35s var(--m-ease), border-color .35s; }
.kwt-lead:hover { transform: translateY(-4px); border-color: rgba(255, 212, 122, .45); }
.kwt-lead-photo { flex: 0 0 auto; width: 128px; height: 128px; padding: 3px; border-radius: 26px; background: linear-gradient(135deg, #ffd47a, var(--m-gold) 45%, #4084d6); }
.kwt-lead-photo img { display: block; width: 100%; height: 100% !important; max-width: none; border-radius: 23px; object-fit: cover; background: #0d2847; }
.kwt-lead-body { min-width: 0; }
.kwt-role { display: inline-block; padding: 4px 11px; border-radius: 999px; background: rgba(255, 212, 122, .14); color: #ffd47a; font-size: 11.5px; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; }
.kwt-lead h3 { margin: 10px 0 4px; font-family: inherit !important; color: #fff; font-size: 22px; font-weight: 700; }
.kwt-meta { margin: 0; color: rgba(232, 238, 247, .72); font-size: 14px; }
.kwt-acts { display: flex; flex-wrap: wrap; justify-content: inherit; gap: 8px; margin-top: 14px; }
.kwt-act { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 38px; height: 38px; padding: 0 12px; border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 999px; background: rgba(255, 255, 255, .06); color: #fff !important; font-size: 13px; font-weight: 600; text-decoration: none !important;
  transition: background-color .2s, border-color .2s, color .2s, transform .2s var(--m-ease); }
.kwt-act span { max-width: 210px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kwt-act:hover { transform: translateY(-2px); border-color: #ffd47a; color: #ffd47a !important; }
.kwt-act.is-solid { border-color: transparent; background: linear-gradient(90deg, #ffd47a, var(--m-gold)); color: #0d2847 !important; }
.kwt-act.is-solid:hover { color: #0d2847 !important; box-shadow: 0 8px 20px rgba(224, 165, 38, .35); }
/* students */
.kwt-sub { display: flex; align-items: center; gap: 16px; margin: 48px 0 24px; color: rgba(232, 238, 247, .85); font-size: 13px; font-weight: 700; letter-spacing: .16em;
  text-transform: uppercase; }
.kwt-sub::before, .kwt-sub::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .25), transparent); }
.kwt-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin: 0; padding: 0; list-style: none; }
.kwt-card { position: relative; display: flex; flex-direction: column; align-items: center; padding: 26px 18px 20px; border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 20px; background: rgba(255, 255, 255, .05); text-align: center; transition: transform .35s var(--m-ease), background-color .35s, border-color .35s; }
.kwt-card:hover { transform: translateY(-6px); background: rgba(255, 255, 255, .09); border-color: rgba(255, 212, 122, .4); }
.kwt-avatar { position: relative; width: 96px; height: 96px; padding: 3px; border-radius: 50%; background: conic-gradient(from 0deg, #ffd47a, var(--m-gold), #4084d6, #ffd47a); }
.kwt-card:hover .kwt-avatar { animation: kwt-spin 3s linear infinite; }
.kwt-card:hover .kwt-avatar img { animation: kwt-spin 3s linear infinite reverse; }
@keyframes kwt-spin { to { transform: rotate(360deg); } }
.kwt-avatar img { display: block; width: 100%; height: 100% !important; max-width: none; border: 3px solid #0d2847; border-radius: 50%; object-fit: cover; background: #0d2847; }
.kwt-batch { margin-top: 14px; padding: 3px 10px; border-radius: 999px; background: rgba(64, 132, 214, .22); color: #bcd6f5; font-size: 11.5px; font-weight: 700; letter-spacing: .06em; }
.kwt-card h4 { margin: 10px 0 4px; font-family: inherit !important; color: #fff; font-size: 16.5px; font-weight: 700; line-height: 1.3; }
.kwt-card p { margin: 0; color: rgba(232, 238, 247, .7); font-size: 13.5px; line-height: 1.45; }
.kwt-card .kwt-acts { justify-content: center; margin-top: auto; padding-top: 14px; }
.kwt-alumni { color: rgba(232, 238, 247, .5); font-size: 12.5px; font-style: italic; line-height: 38px; }
@media (max-width: 1000px) { .kwt-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .kwt-leads { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .kwt-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; } }
@media (max-width: 640px) {
  .kwt { padding: 52px 0 58px; }
  .kwt-inner { padding: 0 16px; }
  .kwt-lead { flex-direction: column; text-align: center; gap: 16px; padding: 22px 18px; }
  .kwt-lead .kwt-acts { justify-content: center; }
  .kwt-card { padding: 20px 10px 16px; }
  .kwt-avatar { width: 80px; height: 80px; }
  .kwt-card h4 { font-size: 15px; }
}

@media (prefers-reduced-motion: reduce) {
  .kab-photo img, .kwt-glow { animation: none; }
  .kwt-card:hover .kwt-avatar, .kwt-card:hover .kwt-avatar img { animation: none; }
  .kab-body .kmx-title::after { transition: none; width: 120px; }
  .krc-viewport.is-moving { overflow-x: auto; -webkit-mask-image: none; mask-image: none; }
  .krc-viewport.is-moving .krc-track { animation: none; }
  .krc-viewport.is-moving .krc-copy { display: none; }
  .krc-tile, .krc-logo img, .kab-facts li { transition: none; }
}
