/* ============================================================
   AI 실무교육 · 통합 진입 페이지
   ============================================================ */

:root {
  --font: "Pretendard", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;

  /* 왼쪽 · 구직자 */
  --seeker-bg: #087147;
  --seeker-point: #20b875;

  /* 오른쪽 · 기업 */
  --company-bg: #17356f;
  --company-point: #2f6beb;

  --text: #fdfdfd;

  --header-h: 72px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100dvh;
  overflow: hidden;
  font-family: var(--font);
  color: var(--text);
  background: var(--seeker-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ===== 헤더 ===== */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 10;
  height: var(--header-h);
  padding: 0 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none; /* 헤더가 패널 클릭을 막지 않도록 */
}

.site-header__brand {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text);
}

.site-header__org {
  font-size: 14px;
  font-weight: 500;
  color: rgba(253, 253, 253, 0.85);
}

/* ===== 게이트웨이 레이아웃 ===== */
.gateway {
  display: flex;
  width: 100vw;
  height: 100dvh;
}

.panel {
  position: relative;
  flex: 1 1 50%;
  min-width: 0;
  height: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  cursor: pointer;
  transition: flex-basis 400ms var(--ease), flex-grow 400ms var(--ease);
  outline: none;
}

.panel--seeker {
  /* 사진 위에 키 컬러 80% 오버레이 */
  background:
    linear-gradient(rgba(8, 113, 71, 0.8), rgba(8, 113, 71, 0.8)),
    var(--seeker-bg) url("images/seeker.png") center / cover no-repeat;
}

.panel--company {
  justify-content: flex-end;
  background:
    linear-gradient(rgba(23, 53, 111, 0.8), rgba(23, 53, 111, 0.8)),
    var(--company-bg) url("images/company.png") center / cover no-repeat;
}

/* 중앙 분리선 — 흰색 10% 1px */
.panel--company::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 1px;
  background: rgba(253, 253, 253, 0.1);
  z-index: 3;
}

/* ===== 배경 그래픽 ===== */
.panel__graphic {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.panel__graphic svg {
  width: 100%;
  height: 100%;
  display: block;
}

.panel__graphic circle,
.panel__graphic path {
  fill: none;
  stroke-width: 1;
  transition: opacity 400ms var(--ease);
}

.panel--seeker .panel__graphic circle,
.panel--seeker .panel__graphic path {
  stroke: var(--seeker-point);
  opacity: 0.08;
}

.panel--company .panel__graphic circle,
.panel--company .panel__graphic path {
  stroke: var(--company-point);
  opacity: 0.08;
}

/* 큰 원 하나는 아주 옅은 면으로 */
.panel__graphic circle:first-child {
  fill: currentColor;
}

.panel--seeker .panel__graphic circle:first-child {
  fill: var(--seeker-point);
  fill-opacity: 0.05;
  stroke: none;
}

.panel--company .panel__graphic circle:first-child {
  fill: var(--company-point);
  fill-opacity: 0.05;
  stroke: none;
}

.panel__graphic {
  transition: opacity 400ms var(--ease);
}

/* ===== 콘텐츠 ===== */
.panel__content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 540px;
  padding: 0 9%;
}

.panel__label {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(253, 253, 253, 0.7);
  margin-bottom: 20px;
}

.panel__title {
  font-size: clamp(40px, 3.6vw, 58px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.03em;
  color: var(--text);
  margin-bottom: 28px;
  word-break: keep-all;
}

.panel__desc {
  font-size: 18px;
  font-weight: 400;
  line-height: 1.65;
  color: rgba(253, 253, 253, 0.78);
  max-width: 440px;
  margin-bottom: 40px;
}

.panel__desc--mobile {
  display: none;
}

/* ===== 버튼 ===== */
.panel__cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  align-self: flex-start;
  height: 52px;
  padding: 0 28px;
  border-radius: 5px;
  background: #fdfdfd;
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}

.panel--seeker .panel__cta {
  color: var(--seeker-bg);
}

.panel--company .panel__cta {
  color: var(--company-bg);
}

.panel__arrow {
  display: inline-block;
  transition: transform 400ms var(--ease);
}

/* ===== 하단 대상 정보 ===== */
.panel__audience {
  position: absolute;
  left: 9%;
  bottom: 56px;
  z-index: 2;
  font-size: 14px;
  font-weight: 500;
  color: rgba(253, 253, 253, 0.6);
}

/* ============================================================
   데스크톱 호버 인터랙션 (JS가 body에 클래스 부여)
   ============================================================ */
@media (min-width: 768px) and (hover: hover) {
  body.hover-left .panel--seeker {
    flex-grow: 1.08; /* ≈ 54% */
  }
  body.hover-left .panel--company {
    flex-grow: 0.92; /* ≈ 46% */
  }
  body.hover-right .panel--company {
    flex-grow: 1.08;
  }
  body.hover-right .panel--seeker {
    flex-grow: 0.92;
  }

  /* 호버 시 포인트 그래픽이 약간 선명해짐 */
  .panel:hover .panel__graphic circle,
  .panel:hover .panel__graphic path {
    opacity: 0.16;
  }
  .panel:hover .panel__arrow {
    transform: translateX(4px);
  }
}

/* 포커스 접근성 — 내부 2px 흰색 테두리 */
.panel:focus-visible {
  outline: 2px solid #fdfdfd;
  outline-offset: -2px;
}

/* ============================================================
   모바일 반응형 — 상하 50:50
   ============================================================ */
@media (max-width: 767px) {
  :root {
    --header-h: 52px;
  }

  .site-header {
    padding: 0 24px;
  }

  .site-header__org {
    display: none;
  }

  .gateway {
    flex-direction: column;
    height: 100dvh;
  }

  .panel {
    flex: 1 1 50%;
    height: 50dvh;
    transition: none;
    padding-top: var(--header-h);
    align-items: center;
  }

  .panel--company {
    justify-content: flex-start;
  }

  .panel--company::before {
    left: 0;
    right: 0;
    top: 0;
    bottom: auto;
    width: auto;
    height: 1px;
  }

  .panel__content {
    max-width: none;
    padding: 0 24px;
  }

  .panel__label {
    font-size: 12px;
    margin-bottom: 14px;
  }

  .panel__title {
    font-size: clamp(28px, 8vw, 32px);
    margin-bottom: 18px;
  }

  .panel__desc {
    font-size: 14px;
    margin-bottom: 24px;
  }

  .panel__desc--full {
    display: none;
  }

  .panel__desc--mobile {
    display: block;
  }

  .panel__cta {
    height: 44px;
    padding: 0 22px;
    font-size: 14px;
  }

  .panel__audience {
    display: none;
  }

  /* 탭 피드백 — 배경이 잠시 진해짐 */
  .panel:active {
    filter: brightness(0.9);
  }
}

/* ============================================================
   모션 최소화 선호
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .panel,
  .panel__arrow,
  .panel__graphic {
    transition: none !important;
  }

  body.hover-left .panel,
  body.hover-right .panel {
    flex-grow: 1 !important;
  }
}
