/* =========================================================
   AKADEMYA PAGE — specific styles
   These extend style.css (which is still loaded first).
   You do NOT need to edit this file to change content —
   use akademya.js for that.
========================================================= */

/* ---- shared page container ---- */
.ak-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

/* =========================================================
   HERO
========================================================= */
.ak-hero {
  position: relative;
  padding: 100px 24px 80px;
  text-align: center;
  overflow: hidden;
}

.ak-hero-content {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: 0 auto;
}

.ak-hero-title {
  font-family: var(--font-display);
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 700;
  line-height: 1.08;
  color: var(--white);
  margin: 0 0 20px;
}

.ak-hero-sub {
  font-size: clamp(16px, 2vw, 19px);
  color: var(--muted);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.6;
}

/* =========================================================
   CURRICULUM
========================================================= */
.ak-curriculum {
  padding: 80px 0 90px;
  border-top: 1px solid var(--border);
}

.ak-course-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.ak-course-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 30px 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.ak-course-card:hover {
  border-color: var(--orange);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(255, 106, 26, 0.12);
}

/* level tag */
.ak-level-tag {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 999px;
  width: fit-content;
}

.level-green {
  background: rgba(52, 211, 153, 0.1);
  border: 1px solid rgba(52, 211, 153, 0.3);
  color: #34d399;
}

.level-blue {
  background: rgba(96, 165, 250, 0.1);
  border: 1px solid rgba(96, 165, 250, 0.3);
  color: #60a5fa;
}

.level-orange {
  background: rgba(255, 106, 26, 0.1);
  border: 1px solid rgba(255, 106, 26, 0.3);
  color: var(--orange-light);
}

.ak-course-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--white);
  margin: 0;
  line-height: 1.3;
}

.ak-course-desc {
  font-size: 14.5px;
  color: var(--muted);
  line-height: 1.65;
  flex: 1;
}

.ak-course-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--orange-light);
  margin-top: 4px;
  transition: gap 0.15s ease, color 0.15s ease;
}

.ak-course-link:hover {
  color: var(--orange);
  gap: 11px;
}

/* =========================================================
   VIDEO LIBRARY
========================================================= */
.ak-videos {
  padding: 80px 0 110px;
  border-top: 1px solid var(--border);
}

/* ---- filter tab strip ---- */
.ak-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 40px;
}

.ak-filter-btn {
  padding: 9px 20px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.ak-filter-btn:hover {
  border-color: var(--orange);
  color: var(--white);
}

.ak-filter-btn.active {
  background: var(--orange);
  border-color: var(--orange);
  color: #15100c;
}

/* ---- video grid ---- */
.ak-video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 24px;
}

.ak-empty {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--muted-2);
  padding: 60px 0;
  font-size: 15px;
}

/* ---- individual video card (is a <button> for accessibility) ---- */
.ak-video-card {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ak-thumb-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface-2);
  border: 1px solid var(--border);
  transition: border-color 0.2s ease;
}

.ak-video-card:hover .ak-thumb-wrap {
  border-color: var(--orange);
}

.ak-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease, filter 0.3s ease;
}

.ak-video-card:hover .ak-thumb {
  transform: scale(1.04);
  filter: brightness(0.65);
}

/* play button overlay */
.ak-play-btn {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.ak-video-card:hover .ak-play-btn { opacity: 1; }

.ak-play-btn svg {
  width: 52px;
  height: 52px;
  color: var(--white);
  filter: drop-shadow(0 2px 12px rgba(0,0,0,0.6));
  background: rgba(255, 106, 26, 0.85);
  border-radius: 50%;
  padding: 12px;
}

/* category badge on thumbnail */
.ak-video-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #15100c;
  background: var(--orange);
  padding: 4px 10px;
  border-radius: 999px;
}

.ak-video-title {
  font-family: var(--font-display);
  font-size: 14.5px;
  font-weight: 600;
  color: var(--white);
  line-height: 1.4;
  margin: 0;
  transition: color 0.15s ease;
}

.ak-video-card:hover .ak-video-title { color: var(--orange-light); }

/* =========================================================
   VIDEO MODAL
========================================================= */
.ak-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.ak-modal[hidden] { display: none; }

.ak-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(6px);
}

.ak-modal-box {
  position: relative;
  z-index: 1;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  overflow: hidden;
  width: 100%;
  max-width: 860px;
  box-shadow: 0 32px 80px rgba(0,0,0,0.7);
}

.ak-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(0,0,0,0.5);
  border: 1px solid var(--border);
  color: var(--white);
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.ak-modal-close:hover {
  background: var(--orange);
  border-color: var(--orange);
  color: #15100c;
}

.ak-modal-player {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.ak-modal-player iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.ak-modal-title {
  padding: 16px 20px;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  color: var(--white);
  margin: 0;
  border-top: 1px solid var(--border);
}

/* =========================================================
   X / TWITTER VIDEO SUPPORT
========================================================= */

/* placeholder thumbnail for X videos that have no image */
.ak-thumb-x {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1a1a1e 0%, #0f0f12 100%);
}

.ak-thumb-x svg {
  width: 46px;
  height: 46px;
  color: var(--white);
  opacity: 0.85;
}

/* small "X" source badge in the top-right of an X card thumbnail */
.ak-source-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid var(--border);
}

.ak-source-badge svg {
  width: 13px;
  height: 13px;
  color: var(--white);
}

/* when the modal is showing an X tweet, it needs to scroll and sit on a
   dark padded surface instead of the fixed 16:9 black video box */
.ak-modal-player.ak-modal-player-x {
  aspect-ratio: auto;
  min-height: 200px;
  max-height: 75vh;
  overflow-y: auto;
  background: var(--surface);
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ak-modal-loading {
  color: var(--muted);
  font-size: 14.5px;
  text-align: center;
  padding: 40px 20px;
}

.ak-modal-loading a {
  color: var(--orange-light);
  font-weight: 600;
  display: inline-block;
  margin-top: 8px;
}

.ak-modal-loading a:hover { color: var(--orange); }

/* =========================================================
   RESPONSIVE
========================================================= */
@media (max-width: 600px) {
  .ak-hero { padding: 70px 20px 60px; }
  .ak-course-grid { grid-template-columns: 1fr; }
  .ak-video-grid { grid-template-columns: 1fr; }
  .ak-modal-box { border-radius: 12px; }
}