/* =========================================================
   공간정보융합연구실 — 밝은 미니멀 아카데믹 테마
   색상/폰트는 :root 변수만 바꾸면 전체에 반영됩니다.
   ========================================================= */
@import url("https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable-dynamic-subset.min.css");

:root {
  --color-primary: #075985;        /* 딥 시안블루 (제목/강조) */
  --color-primary-dark: #0c4a6e;
  --color-accent: #0891b2;         /* 시안 (링크/포인트) */
  --color-accent-2: #2563eb;       /* 블루 (그라데이션 짝) */
  --color-bg: #ffffff;
  --color-bg-soft: #f5f9fb;
  --color-text: #0f172a;
  --color-text-soft: #5b6b7c;
  --color-border: #e6edf2;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px -12px rgba(15, 23, 42, 0.10);
  --shadow-lift: 0 2px 4px rgba(15, 23, 42, 0.05), 0 18px 36px -14px rgba(8, 145, 178, 0.25);
  --grad: linear-gradient(90deg, var(--color-accent), var(--color-accent-2));
  --max-width: 1080px;
  --font-sans: "Pretendard Variable", Pretendard, "Noto Sans KR", "Malgun Gothic", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--color-accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

img { max-width: 100%; display: block; }

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* 그라데이션 텍스트 */
.grad-text {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- 헤더 / 내비게이션 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.nav__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  font-size: 1.12rem;
  letter-spacing: -0.02em;
  color: var(--color-text);
  min-width: 0;
}
.nav__brand:hover { text-decoration: none; color: var(--color-accent); }
.nav__brand span { white-space: nowrap; }
.nav__logo { display: block; width: auto; }
.nav__logo--cwnu { height: 28px; }
.nav__logo--gcl { height: 40px; }
@media (max-width: 560px) {
  .nav__logo--cwnu { display: none; }   /* 좁은 화면에서는 대학 로고 숨김 */
}
.nav__toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.6rem;
  cursor: pointer;
  color: var(--color-text);
}
.nav__menu {
  display: flex;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav__menu a {
  display: block;
  position: relative;
  padding: 8px 14px;
  color: var(--color-text-soft);
  font-weight: 600;
  font-size: 0.94rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
  transition: color 0.15s ease;
}
.nav__menu a:hover { color: var(--color-text); text-decoration: none; }
.nav__menu a.is-active { color: var(--color-accent); }
.nav__menu > li > a.is-active::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 2px;
  height: 2px;
  border-radius: 2px;
  background: var(--grad);
}

/* 드롭다운 (멤버) */
.nav__dropdown { position: relative; }
.nav__submenu {
  position: absolute;
  top: calc(100% + 6px);
  left: 8px;
  min-width: 150px;
  list-style: none;
  margin: 0;
  padding: 8px;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  box-shadow: var(--shadow-lift);
  display: none;
  z-index: 101;
}
.nav__dropdown::after {           /* hover 끊김 방지 브리지 */
  content: "";
  position: absolute;
  left: 0; right: 0;
  top: 100%;
  height: 8px;
}
.nav__dropdown:hover .nav__submenu,
.nav__dropdown:focus-within .nav__submenu { display: block; }
.nav__submenu a {
  white-space: nowrap;
  border-radius: 8px;
  padding: 9px 12px;
}
.nav__submenu a:hover { background: var(--color-bg-soft); color: var(--color-accent); }
.nav__submenu a.is-active::after { display: none; }

/* ---------- 히어로(메인 상단) ---------- */
.hero {
  position: relative;
  padding: 110px 0 100px;
  overflow: hidden;
  background:
    radial-gradient(ellipse 55% 60% at 78% 12%, rgba(8, 145, 178, 0.09), transparent 70%),
    radial-gradient(ellipse 45% 55% at 12% 85%, rgba(37, 99, 235, 0.07), transparent 70%),
    var(--color-bg);
}
.hero::before {                   /* 도트 그리드 패턴 */
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, #c9dae6 1.1px, transparent 1.1px);
  background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(ellipse 75% 90% at 60% 10%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 75% 90% at 60% 10%, #000 20%, transparent 75%);
  pointer-events: none;
}
.hero .container { position: relative; }
.hero__eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin: 0 0 18px;
  padding: 6px 14px;
  border: 1px solid rgba(8, 145, 178, 0.25);
  border-radius: 999px;
  background: rgba(8, 145, 178, 0.05);
}
.hero h1 {
  font-size: clamp(1.9rem, 3.4vw, 2.85rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.24;
  margin: 0 0 20px;
  word-break: keep-all;
}
.hero p {
  font-size: 1.12rem;
  color: var(--color-text-soft);
  max-width: 620px;
  margin: 0 0 34px;
}
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* 히어로 투컬럼 (텍스트 + 3D 모델 미디어) */
.hero__layout {
  display: flex;
  align-items: center;
  gap: 52px;
}
.hero__content { flex: 1; min-width: 0; }
.hero__media {
  position: relative;
  flex: 0 0 42%;
  border-radius: 18px;
  padding: 6px;
  background: linear-gradient(135deg, rgba(8, 145, 178, 0.35), rgba(37, 99, 235, 0.25));
  box-shadow: var(--shadow-lift);
}
.hero__media img {
  width: 100%;
  border-radius: 13px;
  display: block;
  background: var(--color-bg-soft);
}
.hero__media-caption {
  position: absolute;
  left: 16px;
  bottom: 16px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #fff;
  background: rgba(11, 23, 38, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 7px 13px;
  border-radius: 999px;
  max-width: calc(100% - 32px);
}
@media (max-width: 900px) {
  .hero__layout { flex-direction: column; align-items: stretch; gap: 36px; }
  .hero__media { flex: none; }
}

/* ---------- 페이지 헤더(하위 페이지 상단) ---------- */
.page-header {
  position: relative;
  padding: 64px 0 44px;
  border-bottom: 1px solid var(--color-border);
  background:
    radial-gradient(ellipse 50% 90% at 85% 0%, rgba(8, 145, 178, 0.06), transparent 70%),
    var(--color-bg);
}
.page-header h1 {
  margin: 0 0 10px;
  font-size: clamp(1.8rem, 3.4vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}
.page-header h1::after {
  content: "";
  display: block;
  width: 44px;
  height: 4px;
  border-radius: 4px;
  background: var(--grad);
  margin-top: 14px;
}
.page-header p { margin: 0; color: var(--color-text-soft); font-size: 1.02rem; }

/* ---------- 섹션 ---------- */
section { padding: 84px 0; }
section h2 {
  font-size: clamp(1.5rem, 2.6vw, 1.9rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0 0 6px;
}
.section-sub {
  color: var(--color-accent);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 0 0 32px;
}

/* ---------- 버튼 ---------- */
.btn {
  display: inline-block;
  padding: 13px 28px;
  border-radius: 10px;
  background: var(--color-text);
  color: #fff;
  font-weight: 700;
  font-size: 0.96rem;
  letter-spacing: -0.01em;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}
.btn:hover {
  background: var(--color-primary-dark);
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lift);
}
.btn--ghost {
  background: transparent;
  color: var(--color-text);
  border: 1.5px solid var(--color-border);
}
.btn--ghost:hover { background: var(--color-bg-soft); color: var(--color-text); box-shadow: none; }

/* ---------- 카드 그리드 ---------- */
.grid { display: grid; gap: 22px; }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}
.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lift);
  border-color: rgba(8, 145, 178, 0.35);
}
.card h3 {
  margin: 0 0 8px;
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.card p { margin: 0; color: var(--color-text-soft); font-size: 0.95rem; }

/* ---------- 통계(성과 요약) ---------- */
.stat { text-align: center; padding: 30px 20px; }
.stat-num {
  display: block;
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-bottom: 6px;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-variant-numeric: tabular-nums;
}
.stat p { font-size: 0.92rem; }

/* ---------- 멤버 카드 ---------- */
.member { text-align: center; }
.member__photo {
  width: 124px;
  height: 124px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 16px;
  background: var(--color-bg-soft);
  border: 3px solid #fff;
  box-shadow: 0 0 0 1px var(--color-border), 0 6px 16px -6px rgba(15, 23, 42, 0.18);
  transition: box-shadow 0.22s ease;
}
.card:hover .member__photo {
  box-shadow: 0 0 0 2px var(--color-accent), 0 10px 22px -6px rgba(8, 145, 178, 0.35);
}
.member__name { font-weight: 800; font-size: 1.08rem; letter-spacing: -0.02em; margin: 0 0 2px; }
.member__role { color: var(--color-accent); font-size: 0.86rem; font-weight: 600; margin: 0 0 8px; }
.member__desc { color: var(--color-text-soft); font-size: 0.87rem; }

/* ---------- 지도교수 프로필 ---------- */
.prof-hero { display: flex; gap: 40px; align-items: flex-start; flex-wrap: wrap; }
.prof-hero__photo {
  width: 250px;
  height: 310px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lift);
  background: var(--color-bg-soft);
  flex-shrink: 0;
}
.prof-hero__info { flex: 1; min-width: 280px; }
@media (max-width: 600px) {
  .prof-hero__photo { width: 100%; height: auto; max-width: 280px; margin: 0 auto; }
}

/* ---------- 장비 카드 ---------- */
.equip-card { padding: 0; overflow: hidden; }
.equip-card__img {
  background: var(--color-bg-soft);
  height: 185px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  border-bottom: 1px solid var(--color-border);
  overflow: hidden;
}
.equip-card__img img {
  max-height: 100%;
  width: auto;
  object-fit: contain;
  transition: transform 0.3s ease;
}
.equip-card:hover .equip-card__img img { transform: scale(1.06); }
.equip-card__body { padding: 18px 22px 20px; }
.equip-card__body h3 { margin: 0 0 6px; font-size: 1.04rem; }
.equip-card__body p { margin: 0; color: var(--color-text-soft); font-size: 0.88rem; }

/* ---------- 논문/리스트 ---------- */
.pub-list { list-style: none; padding: 0; margin: 0; }
.pub-list li {
  padding: 20px 14px;
  margin: 0 -14px;
  border-bottom: 1px solid var(--color-border);
  border-radius: 10px;
  transition: background 0.15s ease;
}
.pub-list li:hover { background: var(--color-bg-soft); }
.pub-list li:last-child { border-bottom: none; }
.pub-list .pub-venue {
  color: var(--color-accent);
  font-weight: 700;
  font-size: 0.84rem;
  letter-spacing: 0.01em;
}
.pub-list .pub-title { font-weight: 700; letter-spacing: -0.015em; }
.pub-list .pub-authors { color: var(--color-text-soft); font-size: 0.9rem; }

.badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(8, 145, 178, 0.08);
  color: var(--color-accent);
  border: 1px solid rgba(8, 145, 178, 0.2);
}

/* ---------- 탭 ---------- */
.tabs {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.tab-btn {
  background: none;
  border: none;
  padding: 12px 18px;
  font-family: var(--font-sans);
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--color-text-soft);
  cursor: pointer;
  border-bottom: 2.5px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s ease;
}
.tab-btn:hover { color: var(--color-text); }
.tab-btn.is-active { color: var(--color-accent); border-bottom-color: var(--color-accent); }
.tab-panel { display: none; }
.tab-panel.is-active { display: block; animation: panelIn 0.35s ease; }
@keyframes panelIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

/* 검색 입력 */
input[type="search"] {
  font-family: var(--font-sans);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
input[type="search"]:focus {
  outline: none;
  border-color: var(--color-accent) !important;
  box-shadow: 0 0 0 3px rgba(8, 145, 178, 0.12);
}

/* ---------- 표 ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--color-border); border-radius: var(--radius); }
table.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
table.data th, table.data td {
  padding: 13px 16px;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}
table.data thead th {
  background: var(--color-bg-soft);
  color: var(--color-primary);
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
table.data tbody tr:last-child td { border-bottom: none; }
table.data tbody tr { transition: background 0.12s ease; }
table.data tbody tr:hover { background: var(--color-bg-soft); }

/* ---------- 뉴스 ---------- */
.news-list { list-style: none; padding: 0; margin: 0; }
.news-list li {
  display: flex;
  gap: 18px;
  padding: 18px 14px;
  margin: 0 -14px;
  border-bottom: 1px solid var(--color-border);
  border-radius: 10px;
  transition: background 0.15s ease;
}
.news-list li:hover { background: var(--color-bg-soft); }
.news-list .news-date {
  color: var(--color-accent);
  font-size: 0.86rem;
  font-weight: 700;
  min-width: 96px;
  font-variant-numeric: tabular-nums;
}
.news-list .news-title { font-weight: 600; letter-spacing: -0.01em; }

/* ---------- 연락처 ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; }
.info-row { display: flex; gap: 12px; padding: 9px 0; }
.info-row strong { min-width: 80px; color: var(--color-primary); font-weight: 700; }
.map-placeholder {
  background: var(--color-bg-soft);
  border: 1.5px dashed var(--color-border);
  border-radius: var(--radius);
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--color-text-soft);
}

/* ---------- 푸터 ---------- */
.site-footer {
  background: #0b1726;
  color: rgba(255, 255, 255, 0.75);
  padding: 44px 0;
  font-size: 0.92rem;
}
.site-footer a { color: #67e8f9; }
.site-footer strong { color: #fff; }
.site-footer .footer-top { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }

/* ---------- ENVI-LABS 플로팅 버튼 ---------- */
.fab-envilabs {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 90;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px 12px 14px;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  box-shadow: 0 4px 6px rgba(15, 23, 42, 0.06), 0 16px 32px -8px rgba(15, 23, 42, 0.22);
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--color-text);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.fab-envilabs:hover {
  text-decoration: none;
  transform: translateY(-3px);
  box-shadow: 0 6px 10px rgba(15, 23, 42, 0.08), 0 22px 40px -8px rgba(8, 145, 178, 0.35);
}
.fab-envilabs img {
  height: 30px;
  width: auto;
  border-radius: 6px;
}
@media (max-width: 560px) {
  .fab-envilabs { right: 14px; bottom: 14px; padding: 10px 16px 10px 12px; font-size: 0.84rem; }
  .fab-envilabs img { height: 24px; }
}

/* ---------- 사업영역 스텝 도식 (ENVI-LABS) ---------- */
.flow { position: relative; margin-top: 8px; }
.flow::before {                    /* 세로 연결선 */
  content: "";
  position: absolute;
  left: 27px;
  top: 28px;
  bottom: 28px;
  width: 3px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--color-accent), var(--color-accent-2));
  opacity: 0.25;
}
.flow-item {
  position: relative;
  display: flex;
  gap: 22px;
  padding: 18px 0;
}
.flow-num {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.05rem;
  color: #fff;
  background: var(--grad);
  box-shadow: 0 6px 14px -4px rgba(8, 145, 178, 0.5);
  z-index: 1;
}
.flow-card {
  flex: 1;
  display: flex;
  gap: 24px;
  align-items: center;
  flex-wrap: wrap;
}
.flow-card__text { flex: 1.4; min-width: 260px; }
.flow-card__text h3 {
  margin: 4px 0 2px;
  font-size: 1.22rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.flow-card__text h3 small {
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--color-accent);
  letter-spacing: 0;
}
.flow-card__text p { margin: 8px 0 12px; color: var(--color-text-soft); font-size: 0.94rem; }
.flow-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0; list-style: none; }
.flow-chips li {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-primary);
  background: var(--color-bg-soft);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 4px 12px;
}
.flow-card__img {
  flex: 1;
  min-width: 220px;
  max-width: 340px;
}
.flow-card__img img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
}
@media (max-width: 640px) {
  .flow::before { left: 21px; }
  .flow-num { width: 44px; height: 44px; font-size: 0.92rem; }
  .flow-item { gap: 14px; }
}

/* ---------- 스크롤 리빌 애니메이션 ---------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .card, .btn, .equip-card__img img { transition: none; }
}

/* ---------- 반응형 ---------- */
/* 메뉴가 8개라 1080px 이하에서는 햄버거 메뉴로 전환 */
@media (max-width: 1080px) {
  .nav__toggle { display: block; }
  .nav__menu {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    flex-direction: column;
    background: #fff;
    border-bottom: 1px solid var(--color-border);
    padding: 8px 16px 16px;
    gap: 2px;
    display: none;
    box-shadow: 0 16px 32px -16px rgba(15, 23, 42, 0.15);
  }
  .nav__menu.is-open { display: flex; }
  .nav__menu a { padding: 12px; }
  .nav__menu > li > a.is-active::after { display: none; }

  /* 햄버거 메뉴에서는 드롭다운을 펼친 상태로 표시 */
  .nav__submenu {
    position: static;
    display: block;
    border: none;
    box-shadow: none;
    padding: 0 0 0 16px;
    min-width: 0;
  }
  .nav__submenu a { padding: 8px 12px; font-size: 0.92rem; color: var(--color-text-soft); }
}

@media (max-width: 768px) {
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .hero { padding: 70px 0 64px; }
  section { padding: 60px 0; }
}

@media (min-width: 480px) and (max-width: 768px) {
  .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
}
