
/* =========================================================
   NOVA EDUSPACE — HOME PROGRAMS COMPACT REDESIGN
   Scoped to #np-programs only
========================================================= */

#np-programs {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 78px 30px 48px;
    background:
        linear-gradient(180deg, rgba(2, 9, 24, .86), rgba(2, 12, 29, .95)),
        url("/assets/images/programs-bg.webp") center / cover no-repeat;
}

#np-programs .np-programs__inner {
    width: min(1240px, 100%);
    margin: 0 auto;
}

/* HEADER */

#np-programs .np-programs__header {
    max-width: 760px;
    margin: 0 auto 36px;
    text-align: center;
}

#np-programs .np-programs__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 8px 16px;
    margin-bottom: 15px;
    border: 1px solid rgba(77, 211, 255, .28);
    border-radius: 50px;
    background: rgba(9, 30, 55, .65);
    color: #6feaff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .16em;
}

#np-programs .np-programs__header h2 {
    margin: 0;
    color: #fff;
    font-size: clamp(30px, 4vw, 47px);
    line-height: 1.12;
    font-weight: 850;
    letter-spacing: -.045em;
}

#np-programs .np-programs__header h2 span {
    display: inline;
    background: linear-gradient(100deg, #24e0f4, #378dff 65%, #a17aff);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

#np-programs .np-programs__header p {
    max-width: 610px;
    margin: 13px auto 0;
    color: #b8c9df;
    font-size: 14px;
    line-height: 1.7;
}

/* GRID */

#np-programs .np-programs__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-items: stretch;
    gap: 16px;
}

/* CARD */

#np-programs .np-program-card {
    display: flex;
    min-width: 0;
    flex-direction: column;
    padding: 8px;
    overflow: hidden;
    border: 1px solid rgba(112, 176, 235, .22);
    border-radius: 16px;
    background: linear-gradient(
        150deg,
        rgba(9, 28, 52, .96),
        rgba(3, 14, 31, .98)
    );
    box-shadow:
        0 12px 32px rgba(0, 0, 0, .2),
        inset 0 1px rgba(255, 255, 255, .05);
    transition: transform .3s ease, border-color .3s ease,
                box-shadow .3s ease;
}

#np-programs .np-program-card:hover {
    transform: translateY(-5px);
    border-color: rgba(42, 218, 255, .65);
    box-shadow: 0 18px 38px rgba(0, 161, 255, .12);
}

#np-programs .np-card-purple:hover {
    border-color: rgba(171, 133, 255, .7);
}

/* THUMBNAIL */

#np-programs .np-video-thumb {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    flex: 0 0 auto;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 10px;
    background: #020918;
    cursor: pointer;
}

#np-programs .np-video-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s ease;
}

#np-programs .np-video-thumb:hover img {
    transform: scale(1.055);
}

#np-programs .np-video-thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, .08),
        transparent 45%,
        rgba(0, 0, 0, .5)
    );
    pointer-events: none;
}

/* NUMBER */

#np-programs .np-card-number {
    position: absolute;
    z-index: 2;
    top: 10px;
    left: 10px;
    padding: 5px 9px;
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 30px;
    background: rgba(3, 12, 29, .75);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .08em;
}

/* PLAY */

#np-programs .np-play {
    position: absolute;
    z-index: 2;
    top: 50%;
    left: 50%;
    width: 49px;
    height: 49px;
    display: grid;
    place-items: center;
    padding-left: 3px;
    transform: translate(-50%, -50%);
    border: 1px solid rgba(255, 255, 255, .8);
    border-radius: 50%;
    background: rgba(5, 23, 48, .78);
    color: #fff;
    font-size: 17px;
    box-shadow: 0 0 22px rgba(0, 197, 255, .25);
    transition: transform .25s ease, background .25s ease;
}

#np-programs .np-video-thumb:hover .np-play {
    transform: translate(-50%, -50%) scale(1.1);
    background: #168fd9;
}

/* THUMBNAIL LABEL */

#np-programs .np-duration {
    position: absolute;
    z-index: 2;
    right: 10px;
    bottom: 9px;
    padding: 5px 8px;
    border-radius: 5px;
    background: rgba(2, 12, 27, .8);
    color: #e8faff;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .1em;
}

/* CARD INFORMATION */

#np-programs .np-card-info {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr);
    align-items: start;
    gap: 10px;
    min-height: 0;
    padding: 14px 5px 8px;
}

#np-programs .np-program-icon {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    font-size: 16px;
}

#np-programs .np-program-label {
    display: block;
    margin: 0 0 6px;
    color: #5fe5f6;
    font-size: 9px;
    line-height: 1.35;
    font-weight: 800;
    letter-spacing: .09em;
}

#np-programs .np-card-purple .np-program-label {
    color: #b69aff;
}

#np-programs .np-card-copy h3 {
    margin: 0;
    color: #fff;
    font-size: 16px;
    line-height: 1.3;
    font-weight: 800;
    letter-spacing: -.02em;
}

#np-programs .np-card-copy p {
    margin: 7px 0 0;
    color: #afc1d7;
    font-size: 11px;
    line-height: 1.55;
}

/* WATCH BUTTON */

#np-programs .np-watch {
    width: 100%;
    min-height: 37px;
    margin: auto 0 0;
    padding: 0 11px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    border: 1px solid rgba(30, 215, 245, .42) !important;
    border-radius: 8px !important;
    background: rgba(3, 19, 38, .8) !important;
    color: #5de9fa !important;
    font-family: inherit;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: none;
    box-shadow: none !important;
    cursor: pointer;
    transition: background .25s ease, border-color .25s ease;
}

#np-programs .np-watch-purple {
    border-color: rgba(170, 135, 255, .45) !important;
    color: #c1a7ff !important;
}

#np-programs .np-watch:hover {
    transform: none;
    background: rgba(13, 94, 139, .3) !important;
    box-shadow: none !important;
}

#np-programs .np-watch span {
    font-size: 16px;
}

/* FOOTER */

#np-programs .np-programs__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 25px;
    padding: 19px 23px;
    border: 1px solid rgba(100, 180, 255, .2);
    border-radius: 14px;
    background: rgba(8, 29, 53, .68);
}

#np-programs .np-programs__footer-copy > span {
    color: #67e7f7;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .15em;
}

#np-programs .np-programs__footer h3 {
    margin: 5px 0 0;
    color: #fff;
    font-size: 17px;
    line-height: 1.35;
}

#np-programs .np-explore-more {
    min-height: 43px;
    padding: 0 19px;
    gap: 12px;
    border-radius: 50px;
    font-size: 11px;
}

/* TABLET */

@media (max-width: 1050px) {
    #np-programs {
        padding: 65px 22px 40px;
    }

    #np-programs .np-programs__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    #np-programs .np-card-copy h3 {
        font-size: 17px;
    }
}

/* MOBILE */

@media (max-width: 600px) {
    #np-programs {
        padding: 55px 15px 35px;
    }

    #np-programs .np-programs__header {
        margin-bottom: 25px;
    }

    #np-programs .np-programs__header h2 {
        font-size: clamp(28px, 9vw, 38px);
    }

    #np-programs .np-programs__grid {
        grid-template-columns: 1fr;
        max-width: 410px;
        margin: 0 auto;
        gap: 15px;
    }

    #np-programs .np-program-card {
        padding: 8px;
    }

    #np-programs .np-video-thumb {
        aspect-ratio: 16 / 9;
    }

    #np-programs .np-card-info {
        padding: 13px 5px 9px;
    }

    #np-programs .np-card-copy h3 {
        font-size: 17px;
    }

    #np-programs .np-card-copy p {
        font-size: 12px;
    }

    #np-programs .np-programs__footer {
        align-items: stretch;
        flex-direction: column;
        padding: 17px;
    }

    #np-programs .np-explore-more {
        width: 100%;
    }
}

/* REDUCED MOTION */

@media (prefers-reduced-motion: reduce) {
    #np-programs .np-program-card,
    #np-programs .np-video-thumb img,
    #np-programs .np-play {
        transition: none !important;
    }
}

/* NOVA VIDEO MODAL */
#np-video-modal {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

#np-video-modal.is-open {
  display: flex;
}

#np-video-modal .nova-video-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 5, 18, .93);
  backdrop-filter: blur(12px);
}

#np-video-modal .nova-video-modal__panel {
  position: relative;
  z-index: 2;
  width: min(100%, 1050px);
  overflow: hidden;
  border: 1px solid rgba(0, 210, 255, .4);
  border-radius: 20px;
  background: #071326;
  box-shadow: 0 25px 90px rgba(0, 0, 0, .7);
}

.nova-video-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 22px;
  color: white;
}

.nova-video-modal__header h2 {
  margin: 0;
  font-size: 19px;
}

.nova-video-modal__close {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 50%;
  background: rgba(255,255,255,.08);
  color: white;
  font-size: 28px;
  cursor: pointer;
}

.nova-video-modal__frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: black;
}

.nova-video-modal__frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

body.nova-video-active {
  overflow: hidden;
}

#np-video-error {
  padding: 12px 20px;
  color: #ffb5b5;
}

@media (max-width: 600px) {
  #np-video-modal {
    padding: 10px;
  }
}


/* NOVA PROGRAMS — 110% VISUAL SCALE */
#np-programs .np-programs__inner {
  width: min(1500px, calc(110% - 48px));
  max-width: 1500px;
}

#np-programs .np-programs__grid {
  gap: 26px;
}

#np-programs .np-program-card {
  transform: scale(1.05);
  transform-origin: center;
  margin-block: 8px;
}

#np-programs .np-video-thumb {
  aspect-ratio: 4 / 3;
}

#np-programs .np-card-copy h3 {
  font-size: 22px;
}

#np-programs .np-card-copy p {
  font-size: 14px;
  line-height: 1.7;
}

#np-programs .np-play {
  width: 64px;
  height: 64px;
}

@media (max-width: 1050px) {
  #np-programs .np-programs__inner {
    width: calc(100% - 36px);
  }

  #np-programs .np-program-card {
    transform: scale(1.02);
  }
}

@media (max-width: 600px) {
  #np-programs .np-program-card {
    transform: none;
  }
}

/* Reduce ONLY the program cards */
#np-programs .np-program-card {
  transform: scale(0.90);
  transform-origin: center;
}
