/* ============================================================
   반도기연 공통 스타일시트
   ============================================================ */

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

:root {
  --primary:       #0a2d6b;
  --primary-dark:  #061d47;
  --primary-mid:   #103a88;
  --primary-light: #1a5cb8;
  --accent:        #1e7fd4;
  --accent-bright: #2e9de8;
  --white:         #ffffff;
  --light-gray:    #edf0f5;
  --mid-gray:      #e0e6ef;
  --text-dark:     #1a1a2e;
  --text-mid:      #444;
  --text-light:    #777;
  --gold:          #c8a84b;
  --font-ko: 'Noto Sans KR', sans-serif;
  --font-en: 'Oswald', sans-serif;
}

html { scroll-behavior: smooth; }
body { font-family: var(--font-ko); color: var(--text-dark); overflow-x: hidden; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

/* ===== LAYOUT ===== */
.container { max-width: 1280px; margin: 0 auto; padding: 0 40px; }

/* ===== TOP BAR ===== */
.top-bar {
  background: var(--primary-dark);
  color: rgba(255,255,255,0.7);
  font-size: 12px;
  padding: 7px 0;
}
.top-bar-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  gap: 20px;
  align-items: center;
  justify-content: flex-end;
}
.top-bar a { color: rgba(255,255,255,0.7); transition: color .2s; }
.top-bar a:hover { color: #fff; }
.top-bar span { color: rgba(255,255,255,.3); }

/* ===== HEADER / GNB ===== */
header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--white);
  border-bottom: 1px solid var(--mid-gray);
  transition: box-shadow .3s;
}
header.scrolled { box-shadow: 0 4px 24px rgba(10,45,107,.13); }

.gnb-wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  align-items: center;
  height: 80px;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.logo-icon {
  width: 46px; height: 46px;
  background: transparent;
  border-radius: 0;
  display: flex; align-items: center; justify-content: center;
}
.logo-icon svg { width: 30px; height: 30px; fill: #fff; }
.logo-icon img { width: 46px; height: 46px; object-fit: contain; }
.logo-text { display: flex; flex-direction: column; line-height: 1.25; }
.logo-text .main {
  font-family: var(--font-ko);
  font-size: 22px;
  font-weight: 900;
  color: var(--primary-dark);
  letter-spacing: -0.5px;
}
.logo-text .sub {
  font-family: var(--font-ko);
  font-size: 11.5px;
  font-weight: 400;
  color: var(--text-light);
  letter-spacing: 1.5px;
}

/* GNB */
nav.main-nav { margin-left: auto; display: flex; align-items: center; }
.gnb { display: flex; height: 80px; }
.gnb > li { position: relative; display: flex; align-items: center; }
.gnb > li > a {
  display: flex; align-items: center;
  height: 80px; padding: 0 26px;
  font-size: 15px; font-weight: 600;
  color: var(--text-dark);
  letter-spacing: -.3px;
  position: relative;
  transition: color .2s;
}
.gnb > li > a::after {
  content: '';
  position: absolute; bottom: 0; left: 50%;
  transform: translateX(-50%);
  width: 0; height: 3px;
  background: var(--primary);
  transition: width .3s;
}
.gnb > li:hover > a,
.gnb > li.active > a { color: var(--primary); }
.gnb > li:hover > a::after,
.gnb > li.active > a::after { width: 100%; }

/* Dropdown */
.dropdown {
  position: absolute;
  top: 80px; left: 50%;
  transform: translateX(-50%);
  background: var(--white);
  border: 1px solid var(--mid-gray);
  border-top: 3px solid var(--primary);
  min-width: 160px;
  box-shadow: 0 8px 30px rgba(10,45,107,.12);
  opacity: 0; visibility: hidden;
  transition: all .25s;
  pointer-events: none;
}
.gnb > li:hover .dropdown { opacity: 1; visibility: visible; pointer-events: auto; }
.dropdown li a {
  display: block;
  padding: 13px 22px;
  font-size: 13.5px;
  color: var(--text-mid);
  white-space: nowrap;
  transition: all .2s;
  border-bottom: 1px solid var(--light-gray);
}
.dropdown li:last-child a { border-bottom: none; }
.dropdown li a:hover { background: var(--light-gray); color: var(--primary); padding-left: 28px; }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 6px;
  margin-left: auto;
}
.hamburger span { display: block; width: 25px; height: 2px; background: var(--primary); transition: all .3s; }
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile Nav */
.mobile-nav {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: var(--primary-dark);
  z-index: 2000;
  padding: 80px 30px 30px;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform .35s cubic-bezier(.4,0,.2,1);
}
.mobile-nav.open { transform: translateX(0); }
.mobile-nav-close {
  position: absolute; top: 22px; right: 22px;
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: #fff; font-size: 26px;
}
.mobile-menu { display: flex; flex-direction: column; }
.mobile-menu > li > a {
  display: block; padding: 18px 0;
  font-size: 17px; font-weight: 700;
  color: #fff;
  border-bottom: 1px solid rgba(255,255,255,.1);
}
.mobile-sub { display: none; padding: 8px 0 8px 16px; }
.mobile-menu > li.open .mobile-sub { display: block; }
.mobile-sub li a { display: block; padding: 10px 0; font-size: 14px; color: rgba(255,255,255,.7); }

/* ===== PAGE BANNER ===== */
.page-banner {
  /* 기본값: 사진이 없을 때 폴백 그라디언트 */
  background-color: var(--primary-dark);
  background-image: var(--banner-img, none);
  background-size: cover;
  background-position: center;
  padding: 100px 0 90px;
  position: relative;
  overflow: hidden;
}
/* 어두운 오버레이 (사진 위에 겹침) */
.page-banner::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(
    135deg,
    rgba(6, 29, 71, 0.82) 0%,
    rgba(10, 45, 107, 0.70) 50%,
    rgba(16, 58, 136, 0.60) 100%
  );
  z-index: 0;
}
/* 사진이 없을 때 그리드 패턴 보조 */
.page-banner::after {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 60px 60px;
  z-index: 0;
}
.page-banner-inner {
  position: relative; z-index: 1;
}
/* 페이지별 배경사진 — 각 HTML의 .page-banner에 인라인 style로 지정 */
/* 예) style="--banner-img: url('../images/banner_company.jpg')" */
.page-banner .breadcrumb {
  display: flex; align-items: center; gap: 8px;
  font-size: 12px; color: rgba(255,255,255,.65);
  margin-bottom: 22px;
  font-family: var(--font-en);
  letter-spacing: 1.5px;
}
.page-banner .breadcrumb a { color: rgba(255,255,255,.65); transition: color .2s; }
.page-banner .breadcrumb a:hover { color: #fff; }
.page-banner .breadcrumb span { color: rgba(255,255,255,.35); }
.page-banner h1 {
  font-size: 46px; font-weight: 900;
  color: #fff; letter-spacing: -1px;
  margin-bottom: 14px;
  text-shadow: 0 2px 16px rgba(0,0,0,.35);
}
.page-banner .page-title-en {
  display: block;
  font-family: var(--font-en);
  font-size: 12px; letter-spacing: 5px;
  color: var(--gold);
  margin-bottom: 12px;
  text-transform: uppercase;
}
.page-banner p {
  font-size: 15.5px; color: rgba(255,255,255,.8);
  line-height: 1.85;
  text-shadow: 0 1px 8px rgba(0,0,0,.2);
}

/* ===== SECTION COMMON ===== */
section { padding: 90px 0; }
.section-head { text-align: center; margin-bottom: 60px; }
.section-head .label {
  display: inline-block;
  font-family: var(--font-en);
  font-size: 11px; letter-spacing: 4px;
  color: var(--accent);
  background: rgba(30,127,212,.08);
  padding: 6px 16px; border-radius: 2px;
  margin-bottom: 16px;
}
.section-head h2 {
  font-size: 36px; font-weight: 800;
  color: var(--primary-dark); letter-spacing: -1px; margin-bottom: 16px;
}
.section-head p { font-size: 15.5px; color: var(--text-light); line-height: 1.9; }
.divider { width: 50px; height: 3px; background: var(--primary); margin: 18px auto 0; }

/* Left-aligned section head (for inner pages) */
.section-head.left { text-align: left; }
.section-head.left .divider { margin: 18px 0 0; }

/* ===== CARDS ===== */
.card-grid-3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 28px; }
.card-grid-2 { display: grid; grid-template-columns: repeat(2,1fr); gap: 28px; }

/* ===== INQUIRY BANNER ===== */
.inquiry-banner {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-mid) 40%, var(--accent) 100%);
  padding: 80px 0;
  position: relative; overflow: hidden;
}
.inquiry-banner::before {
  content: ''; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 50px 50px;
}
.inquiry-inner { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 40px; }
.inquiry-text .label { font-family: var(--font-en); font-size: 11px; letter-spacing: 3px; color: var(--gold); display: block; margin-bottom: 12px; }
.inquiry-text h2 { font-size: 30px; font-weight: 900; color: #fff; letter-spacing: -.5px; margin-bottom: 10px; }
.inquiry-text p { font-size: 14.5px; color: rgba(255,255,255,.75); line-height: 1.8; }
.inquiry-btn {
  display: inline-flex; align-items: center; gap: 10px;
  background: #fff; color: var(--primary);
  font-size: 15px; font-weight: 800;
  padding: 18px 36px; border-radius: 3px;
  flex-shrink: 0; transition: all .3s;
  letter-spacing: -.3px;
}
.inquiry-btn:hover { background: var(--gold); color: #fff; }
.inquiry-btn svg { width: 20px; height: 20px; }

/* ===== FOOTER (사업자정보만) ===== */
footer { background: var(--primary-dark); color: rgba(255,255,255,.6); }

.footer-biz-info {
  padding: 36px 0 28px;
  border-top: 1px solid rgba(255,255,255,.08);
}
.footer-biz-logo {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 16px;
}
.footer-logo-icon { width: 46px; height: 46px; background: transparent; display: flex; align-items: center; justify-content: center; }
.footer-logo-icon img { width: 46px; height: 46px; object-fit: contain; }
.footer-brand { display: flex; flex-direction: column; line-height: 1.3; }
.footer-brand-name { font-size: 16px; font-weight: 800; color: #fff; letter-spacing: -.3px; }
.footer-brand-sub { font-size: 11px; font-weight: 400; color: rgba(255,255,255,.5); letter-spacing: 1px; margin-top: 2px; }
.footer-brand-name { font-size: 15px; font-weight: 700; color: #fff; }

.footer-biz-text {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  font-size: 12.5px;
  color: rgba(255,255,255,.55);
  margin-bottom: 14px;
  line-height: 1.9;
}
.footer-biz-text span { display: inline-flex; align-items: center; gap: 4px; }
.footer-biz-text strong { color: rgba(255,255,255,.82); }
.footer-sep { display: none; } /* | 완전 숨김 */

.footer-copy {
  font-size: 12px; color: rgba(255,255,255,.35);
}
.footer-copy a {
  color: rgba(255,255,255,.45);
  text-decoration: underline;
  transition: color .2s;
}
.footer-copy a:hover { color: #fff; }

@media (max-width: 768px) {
  .footer-biz-text { flex-direction: column; gap: 2px; }
}

/* ===== FLOATING ===== */
.floating-btns { position: fixed; right: 30px; bottom: 100px; z-index: 900; display: flex; flex-direction: column; gap: 10px; }
.float-btn {
  width: 50px; height: 50px;
  background: var(--primary); color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 16px rgba(10,45,107,.3);
  cursor: pointer; transition: all .3s;
  text-decoration: none; border: none;
}
.float-btn:hover { background: var(--accent); transform: translateY(-3px); }
.float-btn svg { width: 20px; height: 20px; fill: #fff; }
.float-btn.top-btn { background: rgba(10,45,107,.7); }
.float-btn.top-btn:hover { background: var(--primary); }

/* ===== SCROLL ANIMATION ===== */
.fade-up { opacity: 0; transform: translateY(40px); transition: opacity .7s, transform .7s; }
.fade-up.visible { opacity: 1; transform: translateY(0); }
.fade-up:nth-child(2) { transition-delay: .15s; }
.fade-up:nth-child(3) { transition-delay: .3s; }
.fade-up:nth-child(4) { transition-delay: .45s; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
  .card-grid-3 { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 768px) {
  .top-bar { display: none; }
  .gnb-wrap { padding: 0 20px; }
  nav.main-nav { display: none; }
  .hamburger { display: flex; }
  .mobile-nav { display: block; }
  section { padding: 60px 0; }
  .container { padding: 0 20px; }
  .section-head h2 { font-size: 26px; }
  .card-grid-3, .card-grid-2 { grid-template-columns: 1fr; }
  .inquiry-inner { flex-direction: column; text-align: center; }
  .inquiry-btn { width: 100%; justify-content: center; }
  .floating-btns { right: 16px; bottom: 80px; }
  .page-banner { padding: 70px 0 60px; }
  .page-banner h1 { font-size: 30px; }
  .page-banner p { font-size: 14px; }
}
@media (max-width: 480px) {
  .page-banner { padding: 56px 0 48px; }
  .page-banner h1 { font-size: 26px; }
}
