/* 메인 랜딩 패널 전용 스타일 (기존 layout CSS와 격리) */

.main-landing-panel {
  --ml-bg-deep: #050b1a;
  --ml-bg-navy: #0a1428;
  --ml-title-navy: #1a2847;
  --ml-title-red: #c8102e;
  --ml-foot-text: #a8b3c7;
  --ml-divider: rgba(255, 255, 255, 0.08);

  position: relative;
  height: 100%;
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo',
               'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: #ffffff;
  background: var(--ml-bg-deep);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.main-landing-panel a {
  color: inherit;
  text-decoration: none;
}

.main-landing-panel img {
  display: block;
  max-width: 100%;
}

.main-landing-panel .ml-page {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.main-landing-panel .ml-hero {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  background-color: var(--ml-bg-navy);
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  padding: 56px 64px 48px;
  overflow: hidden;
}

.main-landing-panel .ml-hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 200px;
  background: linear-gradient(180deg, rgba(5, 11, 26, 0) 0%, rgba(5, 11, 26, 0.85) 100%);
  pointer-events: none;
}

.main-landing-panel .ml-hero-inner {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
}

.main-landing-panel .ml-brand {
  display: inline-block;
  margin-bottom: 56px;
  line-height: 0;
}

.main-landing-panel .ml-brand img {
  height: 30px;
  width: auto;
}

.main-landing-panel .ml-hero-headline {
  margin-bottom: 64px;
}

.main-landing-panel .ml-hero-title {
  font-size: clamp(28px, 3.4vw, 44px);
  font-weight: 700;
  line-height: 1.32;
  letter-spacing: -0.02em;
  color: #ffffff;
  margin-bottom: 0;
}

.main-landing-panel .ml-hero-subtitle {
  margin: 16px 0 0;
  font-size: clamp(15px, 1.5vw, 20px);
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: -0.01em;
  color: rgba(255, 255, 255, 0.92);
}

.main-landing-panel .ml-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  align-items: center;
  max-width: 1100px;
  margin: 0 auto;
}

.main-landing-panel .ml-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border: 4px solid transparent;
  border-radius: 12px;
  background:
    linear-gradient(180deg,
      rgba(220, 226, 237, 0.95) 0%,
      rgba(240, 244, 255, 0.95) 30%,
      rgba(240, 244, 255, 0.95) 61%,
      rgba(220, 226, 237, 0.95) 84%,
      rgba(220, 226, 237, 0.95) 100%) padding-box,
    linear-gradient(135deg,
      rgba(255, 255, 255, 0.95) 0%,
      rgba(255, 255, 255, 0.20) 50%,
      rgba(255, 255, 255, 0.65) 100%) border-box;
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  padding: 26px 26px 22px;
  aspect-ratio: 336 / 406;
  color: var(--ml-title-navy);
  box-shadow:
    0 14px 30px rgba(0, 0, 0, 0.32),
    inset 0 1px 1px rgba(255, 255, 255, 0.7),
    inset 0 -1px 2px rgba(255, 255, 255, 0.25);
  transition: transform .4s cubic-bezier(.2, .7, .2, 1),
              box-shadow .4s cubic-bezier(.2, .7, .2, 1);
  overflow: hidden;
}

.main-landing-panel .ml-card--mid {
  transform: translateY(-32px);
}

.main-landing-panel .ml-card:hover,
.main-landing-panel .ml-card:focus-visible {
  transform: translateY(-12px);
  box-shadow:
    0 28px 56px rgba(0, 0, 0, 0.45),
    inset 0 1px 1px rgba(255, 255, 255, 0.8),
    inset 0 -1px 2px rgba(255, 255, 255, 0.3);
}

.main-landing-panel .ml-card--mid:hover,
.main-landing-panel .ml-card--mid:focus-visible {
  transform: translateY(-44px);
}

.main-landing-panel .ml-card:focus-visible {
  outline: 2px solid #ff3047;
  outline-offset: 4px;
}

.main-landing-panel .ml-card-mark {
  display: block;
  margin-bottom: 10px;
  line-height: 0;
}

.main-landing-panel .ml-card-mark img {
  height: 35px;
  width: auto;
}

.main-landing-panel .ml-card-title {
  font-size: clamp(22px, 1.9vw, 30px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 8px;
  color: var(--ml-title-navy);
  transition: color .25s ease;
}

.main-landing-panel .ml-m-arrow {
  display: none;
}

.main-landing-panel .ml-card:hover .ml-card-title {
  color: var(--ml-title-red);
}

.main-landing-panel .ml-illu {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 6px 0 4px;
  overflow: hidden;
}

.main-landing-panel .ml-illu img {
  max-width: 100%;
  max-height: 100%;
  height: auto;
  object-fit: contain;
  transition: transform .5s cubic-bezier(.2, .7, .2, 1);
}

.main-landing-panel .ml-card:hover .ml-illu img {
  transform: scale(1.06) rotate(-1deg);
}

.main-landing-panel .ml-cta {
  align-self: flex-end;
  font-size: 13px;
  font-weight: 600;
  color: var(--ml-title-navy);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap .25s ease, color .25s ease;
}

.main-landing-panel .ml-cta::after {
  content: "→";
  transition: transform .25s ease;
}

.main-landing-panel .ml-card:hover .ml-cta {
  gap: 12px;
  color: var(--ml-title-red);
}

.main-landing-panel .ml-card:hover .ml-cta::after {
  transform: translateX(4px);
}

.main-landing-panel .ml-footer {
  background: var(--ml-bg-deep);
  padding: 20px 64px 28px;
  flex-shrink: 0;
}

.main-landing-panel .ml-footer-inner {
  max-width: 1280px;
  margin: 0 auto;
}

.main-landing-panel .ml-footer-top {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 14px;
}

.main-landing-panel .ml-footer .ml-brand {
  margin-bottom: 0;
}

.main-landing-panel .ml-footer .ml-brand img {
  height: 30px;
}

.main-landing-panel .ml-footer-brand-row {
  display: flex;
  align-items: end;
  gap: 15px;
}

.main-landing-panel .ml-brand-divider {
  width: 1px;
  height: 16px;
  background: rgba(255, 255, 255, 0.18);
  margin-bottom: 3px;
}

.main-landing-panel .ml-footer-link {
  font-size: 14px;
  color: #eeeeee;
}

.main-landing-panel .ml-footer-link:hover {
  color: #ff3047;
}

.main-landing-panel .ml-footer-copy {
  font-size: 13px;
  color: var(--ml-foot-text);
}

.main-landing-panel .ml-footer-divider {
  height: 1px;
  background: var(--ml-divider);
  margin: 4px 0 16px;
}

.main-landing-panel .ml-footer-info {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  font-size: 12px;
  color: var(--ml-foot-text);
  line-height: 1.85;
}

.main-landing-panel .ml-footer-info p {
  word-break: keep-all;
  margin: 0;
}

/* 스크롤 힌트 */
.main-landing-scroll-hint {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.75);
  cursor: pointer;
  font-size: 11px;
  letter-spacing: 0.12em;
  font-weight: 600;
}

.main-landing-scroll-hint__arrow {
  display: block;
  width: 18px;
  height: 18px;
  border-right: 2px solid rgba(255, 255, 255, 0.7);
  border-bottom: 2px solid rgba(255, 255, 255, 0.7);
  transform: rotate(45deg);
  animation: mainLandingBounce 1.6s ease-in-out infinite;
}

@keyframes mainLandingBounce {
  0%, 100% { transform: rotate(45deg) translateY(0); opacity: 0.6; }
  50% { transform: rotate(45deg) translateY(6px); opacity: 1; }
}

/* ===== 에듀윌식 오버레이 구조 ===== */
html.main-landing-page,
html.main-landing-page body.main-landing-body,
html.main-landing-snap-enabled,
html.main-landing-snap-enabled body.main-landing-body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

html.main-skip-landing-init .main-snap-panel--site {
  transform: translateY(0);
  transition: none;
}

.main-snap-root {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

/* 랜딩: 고정 배경, 스크롤 없음 */
.main-snap-panel--landing {
  position: fixed;
  inset: 0;
  z-index: 1;
  height: 100vh;
  overflow: hidden;
}

/* 메인: 화면 아래 대기 → 위로 슬라이드하며 덮음 */
.main-snap-panel--site {
  position: fixed;
  inset: 0;
  z-index: 10;
  height: 100vh;
  background: #fff;
  transform: translateY(100%);
  transition: transform 0.75s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.18);
  will-change: transform;
}

.main-snap-panel--site.is-covered {
  transform: translateY(0);
}

.main-snap-panel--site.no-transition {
  transition: none !important;
}

/* 메인 노출 시에만 내부 스크롤 (스크롤바 1개) */
.main-site-scroll {
  height: 100vh;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  background: #fff;
}

.main-site-content {
  overflow: visible;
  position: relative;
}

@media (max-width: 800px) {
  .main-landing-panel .ml-hero {
    padding: 40px 24px 32px;
    text-align: center;
  }

  .main-landing-panel .ml-hero::after {
    height: 140px;
  }

  .main-landing-panel .ml-brand {
    margin-bottom: 40px;
  }

  .main-landing-panel .ml-brand img {
    height: 24px;
  }

  .main-landing-panel .ml-hero-headline {
    margin-bottom: 36px;
  }

  .main-landing-panel .ml-hero-title {
    font-size: 22px;
    line-height: 1.4;
  }

  .main-landing-panel .ml-hero-subtitle {
    margin-top: 10px;
    font-size: 14px;
    line-height: 1.45;
  }

  .main-landing-panel .ml-cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    max-width: 460px;
  }

  .main-landing-panel .ml-card {
    padding: 18px 16px 16px;
    aspect-ratio: 1 / 1.18;
    border-radius: 10px;
  }

  .main-landing-panel .ml-card--mid {
    transform: none;
  }

  .main-landing-panel .ml-card--mid:hover {
    transform: translateY(-10px);
  }

  .main-landing-panel .ml-card:hover {
    transform: translateY(-10px);
  }

  .main-landing-panel .ml-card-mark {
    margin-bottom: 8px;
  }

  .main-landing-panel .ml-card-mark img {
    height: 24px;
  }

  .main-landing-panel .ml-card-title {
    font-size: 17px;
    line-height: 1.25;
  }

  .main-landing-panel .ml-illu img {
    width: 78%;
  }

  .main-landing-panel .ml-cta {
    font-size: 11px;
  }

  .main-landing-panel .ml-card--3 {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    aspect-ratio: auto;
    padding: 14px 18px;
  }

  .main-landing-panel .ml-card--3 .ml-card-mark {
    margin-bottom: 0;
  }

  .main-landing-panel .ml-card--3 .ml-card-mark img {
    height: 28px;
  }

  .main-landing-panel .ml-card--3 .ml-card-title {
    font-size: 14px;
    font-weight: 700;
    margin: 0;
  }

  .main-landing-panel .ml-card--3 .ml-prefix {
    display: none;
  }

  .main-landing-panel .ml-card--3 .ml-m-arrow {
    display: inline;
  }

  .main-landing-panel .ml-card--3 .ml-illu,
  .main-landing-panel .ml-card--3 .ml-cta {
    display: none;
  }

  .main-landing-panel .ml-footer {
    padding: 16px 24px 24px;
  }

  .main-landing-panel .ml-footer .ml-brand img {
    height: 22px;
  }

  .main-landing-panel .ml-brand-divider {
    height: 14px;
    margin-bottom: 2px;
  }

  .main-landing-panel .ml-footer-link {
    font-size: 12px;
  }

  .main-landing-panel .ml-footer-info {
    grid-template-columns: 1fr;
    gap: 18px;
    font-size: 11.5px;
  }

  .main-landing-panel .ml-footer-copy {
    font-size: 11.5px;
  }
}

@media (max-width: 380px) {
  .main-landing-panel .ml-hero {
    padding: 32px 18px 24px;
  }

  .main-landing-panel .ml-footer {
    padding: 14px 18px 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .main-landing-panel .ml-card,
  .main-landing-panel .ml-illu img,
  .main-landing-panel .ml-cta,
  .main-landing-panel .ml-cta::after {
    transition: none !important;
  }

  .main-landing-panel .ml-card:hover,
  .main-landing-panel .ml-card--mid:hover {
    transform: none;
  }

  .main-landing-scroll-hint__arrow {
    animation: none;
  }

  .main-snap-panel--site {
    transition: none !important;
  }
}
