/* HD현대일렉트릭 특약점 - 커스텀 스타일 */

/* 사이트 로고 — 명함 템플릿 스타일 */
.site-logo {
  display: inline-block;
  text-decoration: none;
  line-height: 1;
}

.site-logo__wrap {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

.site-logo__img {
  height: 22px;
  width: auto;
  display: block;
  object-fit: contain;
}

@media (min-width: 640px) {
  .site-logo__img {
    height: 26px;
  }
}

@media (min-width: 1024px) {
  .site-logo__img {
    height: 28px;
  }
}

/* 명함: "특약점 | OOOO(주)" — 로고 오른쪽 끝선에 맞춤 */
.site-logo__dealer {
  align-self: flex-end;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: #1a1a1a;
  line-height: 1.3;
  white-space: nowrap;
}

@media (min-width: 640px) {
  .site-logo__dealer {
    font-size: 12px;
  }
}

@media (min-width: 1024px) {
  .site-logo__dealer {
    font-size: 13px;
  }
}

.site-logo__dealer-sep {
  color: #999;
  margin: 0 3px;
  font-weight: 400;
}

/* 푸터 로고 */
.site-logo--footer .site-logo__img {
  height: 24px;
  filter: brightness(0) invert(1);
  opacity: 0.92;
}

.site-logo--footer .site-logo__dealer {
  color: #cbd5e1;
}

.site-logo--footer .site-logo__dealer-sep {
  color: #64748b;
}

:root {
  --hd-discovery-blue: #003087;
  --hd-trust-blue: #002554;
  --hd-light-blue: #e8f0fa;
  --hd-accent-blue: #1a5cb8;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Hero 섹션 */
.hero-section {
  background: linear-gradient(160deg, #001a42 0%, var(--hd-trust-blue) 40%, #001530 100%);
}

.hero-bg-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.2s ease;
  filter: blur(3px) brightness(0.55) saturate(1.2);
  transform: scale(1.08);
  animation: hero-kenburns 18s ease-in-out infinite alternate;
}

.hero-bg-slide.active {
  opacity: 0.5;
}

@keyframes hero-kenburns {
  0% { transform: scale(1.06) translate(0, 0); }
  100% { transform: scale(1.12) translate(-1%, -0.5%); }
}

.hero-bg-mesh {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 15% 30%, rgba(26, 92, 184, 0.35) 0%, transparent 70%),
    radial-gradient(ellipse 50% 40% at 85% 70%, rgba(0, 80, 180, 0.28) 0%, transparent 70%),
    radial-gradient(ellipse 40% 35% at 50% 90%, rgba(100, 160, 255, 0.12) 0%, transparent 60%);
  animation: hero-mesh-drift 12s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes hero-mesh-drift {
  0% { opacity: 0.85; transform: scale(1); }
  100% { opacity: 1; transform: scale(1.03); }
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 20%, transparent 75%);
  pointer-events: none;
}

.hero-overlay {
  background:
    radial-gradient(ellipse 55% 45% at 50% 38%, rgba(0, 48, 135, 0.15) 0%, transparent 65%),
    radial-gradient(ellipse 90% 75% at 50% 50%, transparent 30%, rgba(0, 20, 50, 0.55) 100%),
    linear-gradient(180deg, rgba(0, 37, 84, 0.4) 0%, rgba(0, 37, 84, 0.75) 50%, rgba(0, 25, 60, 0.95) 100%);
}

.hero-rays {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(115deg, transparent 40%, rgba(255, 255, 255, 0.04) 49%, rgba(255, 255, 255, 0.06) 50%, rgba(255, 255, 255, 0.04) 51%, transparent 60%),
    linear-gradient(245deg, transparent 35%, rgba(100, 180, 255, 0.05) 48%, rgba(100, 180, 255, 0.08) 50%, rgba(100, 180, 255, 0.05) 52%, transparent 65%);
  pointer-events: none;
}

.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
}

.hero-glow--left {
  top: 15%;
  left: -8%;
  width: 420px;
  height: 420px;
  background: rgba(26, 92, 184, 0.3);
  animation: hero-glow-pulse 8s ease-in-out infinite alternate;
}

.hero-glow--right {
  bottom: 5%;
  right: -8%;
  width: 380px;
  height: 380px;
  background: rgba(0, 100, 200, 0.22);
  animation: hero-glow-pulse 10s ease-in-out infinite alternate-reverse;
}

.hero-glow--center {
  top: 35%;
  left: 50%;
  transform: translateX(-50%);
  width: 500px;
  height: 300px;
  background: rgba(80, 140, 255, 0.12);
  filter: blur(100px);
  animation: hero-glow-pulse 6s ease-in-out infinite alternate;
}

@keyframes hero-glow-pulse {
  0% { opacity: 0.6; transform: scale(1); }
  100% { opacity: 1; transform: scale(1.08); }
}

.hero-glow--center {
  animation-name: hero-glow-pulse-center;
}

@keyframes hero-glow-pulse-center {
  0% { opacity: 0.5; transform: translateX(-50%) scale(1); }
  100% { opacity: 0.9; transform: translateX(-50%) scale(1.1); }
}

/* Hero 중앙 레이아웃 */
.hero-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.hero-carousel {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  width: 100%;
  max-width: 640px;
}

.hero-showcase {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-showcase-title {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.12em;
  margin: 0 0 18px;
  padding: 8px 20px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.hero-showcase-card {
  position: relative;
  width: 100%;
}

/* HG 라인업 배너 — 히어로 아래, 가로 맞춤 + 양옆 흰색 자연스럽게 */
.hero-lineup-banner {
  width: 100%;
  background: #fff;
  display: flex;
  justify-content: center;
}

.hero-lineup-banner__inner {
  width: min(1280px, 94vw);
  padding: 12px 0;
  background: #fff;
}

.hero-lineup-banner__frame {
  width: 100%;
  overflow: hidden;
  line-height: 0;
  background: #fff;
}

.hero-lineup-banner__img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  border: none;
  outline: none;
  /* 상·하 흰 여백 + 좌우 이미지 테두리선만 미세 제거 */
  clip-path: inset(11% 0.7% 14% 0.7%);
  margin-top: -11%;
  margin-bottom: -14%;
}

@media (min-width: 640px) {
  .hero-lineup-banner__inner {
    padding: 14px 0;
  }

  .hero-lineup-banner__img {
    clip-path: inset(12% 0.7% 15% 0.7%);
    margin-top: -12%;
    margin-bottom: -15%;
  }
}

@media (min-width: 1024px) {
  .hero-lineup-banner__inner {
    padding: 16px 0;
  }

  .hero-lineup-banner__img {
    clip-path: inset(12% 0.7% 16% 0.7%);
    margin-top: -12%;
    margin-bottom: -16%;
  }
}

.hero-showcase-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(255,255,255,0.55) 0%, rgba(255,255,255,0.08) 45%, rgba(255,255,255,0.35) 100%);
  z-index: 0;
}

.hero-arrow {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  color: #fff;
  cursor: pointer;
  transition: background 0.25s ease, border-color 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
  backdrop-filter: blur(8px);
  z-index: 2;
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.5);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
}

.hero-arrow:active {
  transform: scale(0.92);
}

.hero-featured-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, #ffffff 0%, #f0f4fa 100%);
  border-radius: 24px;
  padding: 36px 32px;
  height: 260px;
  text-decoration: none;
  box-shadow:
    0 25px 60px rgba(0, 0, 0, 0.25),
    0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-featured-inner:hover {
  transform: translateY(-4px);
  box-shadow:
    0 32px 70px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.15) inset;
}

.hero-featured-inner img {
  max-width: 100%;
  max-height: 220px;
  object-fit: contain;
  transition: opacity 0.4s ease, transform 0.4s ease;
  filter: drop-shadow(0 8px 16px rgba(0, 48, 135, 0.12));
}

.hero-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 28px;
}

.hero-featured-link {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  letter-spacing: -0.02em;
  transition: color 0.2s ease;
}

.hero-featured-link:hover {
  color: #a8c8f0;
}

.hero-counter {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 0.08em;
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-product-desc {
  margin-top: 14px;
  max-width: 520px;
  font-size: 14px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.65);
  min-height: 48px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 28px;
}

.hero-btn {
  padding: 12px 24px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.hero-btn:hover {
  transform: translateY(-1px);
}

.hero-btn--primary {
  background: #fff;
  color: var(--hd-discovery-blue);
}

.hero-btn--primary:hover {
  background: var(--hd-light-blue);
}

.hero-btn--secondary {
  background: #38bdf8;
  color: #002554;
  border: 1px solid #7dd3fc;
}

.hero-btn--secondary:hover {
  background: #7dd3fc;
}

.hero-btn--accent {
  background: #fbbf24;
  color: #422006;
  border: 1px solid #fcd34d;
}

.hero-btn--accent:hover {
  background: #fcd34d;
}

@media (min-width: 640px) {
  .hero-carousel {
    gap: 24px;
    max-width: 720px;
  }

  .hero-showcase-title {
    font-size: 17px;
    margin-bottom: 22px;
    padding: 10px 26px;
  }

  .hero-featured-inner {
    height: 320px;
    padding: 44px 40px;
  }

  .hero-featured-inner img {
    max-height: 280px;
  }

  .hero-arrow {
    width: 52px;
    height: 52px;
  }

  .hero-featured-link {
    font-size: 20px;
  }
}

/* 제품소개 페이지 */
.product-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

@media (max-width: 1023px) {
  .product-nav {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 8px;
    gap: 8px;
    -webkit-overflow-scrolling: touch;
  }
}

.product-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  flex-shrink: 0;
}

@media (max-width: 1023px) {
  .product-nav-item {
    flex-direction: column;
    width: 100px;
    padding: 10px 8px;
    text-align: center;
    gap: 6px;
  }
}

.product-nav-item:hover {
  border-color: var(--hd-discovery-blue);
  background: var(--hd-light-blue);
}

.product-nav-item.active {
  border-color: var(--hd-discovery-blue);
  background: var(--hd-light-blue);
  box-shadow: 0 4px 12px rgba(0, 48, 135, 0.1);
}

.product-nav-item img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  flex-shrink: 0;
}

@media (max-width: 1023px) {
  .product-nav-item img {
    width: 48px;
    height: 48px;
  }
}

.product-nav-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--hd-dark);
  line-height: 1.3;
}

.product-nav-code {
  font-size: 11px;
  color: #6b7280;
}

.product-nav-code:empty {
  display: none;
}

@media (min-width: 1024px) {
  .product-nav-name,
  .product-nav-code {
    display: block;
  }
}

.product-detail {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 28px;
}

@media (min-width: 640px) {
  .product-detail {
    padding: 36px;
  }
}

.product-detail-image {
  background: #f8fafc;
  border-radius: 12px;
  padding: 32px;
  margin: 24px 0;
  text-align: center;
}

.product-detail-image img {
  max-width: 100%;
  max-height: 320px;
  object-fit: contain;
}

.product-detail-specs {
  display: grid;
  gap: 24px;
}

@media (min-width: 640px) {
  .product-detail-specs {
    grid-template-columns: 1fr 1fr;
  }
}

.product-spec-block h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--hd-dark);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--hd-discovery-blue);
}

.product-spec-block ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.product-spec-block li {
  position: relative;
  padding-left: 14px;
  margin-bottom: 8px;
  font-size: 14px;
  color: #4b5563;
  line-height: 1.6;
}

.product-spec-block li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--hd-discovery-blue);
  font-weight: bold;
}

.product-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid #e5e7eb;
}

.cert-badge {
  display: inline-block;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 600;
  color: var(--hd-dark);
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
}


/* 네비게이션 — iOS Safari 터치·레이어 이슈 방지 */
#main-nav {
  z-index: 1000;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
}

#mobile-menu-toggle {
  position: relative;
  z-index: 1001;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  cursor: pointer;
}

#mobile-menu {
  position: relative;
  z-index: 1001;
}

@media (max-width: 767px) {
  #main-nav {
    background-color: rgba(255, 255, 255, 0.98) !important;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

/* 서브페이지 히어로 — fixed 헤더 아래에서 시작 (iOS 터치 가로채기 방지) */
.page-hero {
  margin-top: 4rem;
  padding-top: 2.5rem;
}

@media (min-width: 1024px) {
  .page-hero {
    margin-top: 5rem;
    padding-top: 3rem;
  }
}

/* 네비게이션 스크롤 효과 */
.nav-scrolled {
  background-color: rgba(255, 255, 255, 0.98) !important;
  box-shadow: 0 2px 20px rgba(0, 37, 84, 0.08);
}

/* 카드 호버 */
.service-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 48, 135, 0.12);
}

/* 자료실 Google Drive 링크 카드 */
.resource-link-card {
  display: block;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  overflow: hidden;
  background: #fff;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.resource-link-card:hover {
  border-color: var(--hd-discovery-blue);
  box-shadow: 0 12px 32px rgba(0, 48, 135, 0.12);
  transform: translateY(-2px);
}

.resource-link-card--pending {
  cursor: default;
  opacity: 0.72;
}

.resource-link-card--pending:hover {
  transform: none;
  box-shadow: none;
  border-color: #e5e7eb;
}

.resource-link-card__img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 5 / 3;
  object-fit: cover;
  object-position: center;
  background: #f3f4f6;
}

.resource-link-card__body {
  padding: 1rem 1.25rem 1.25rem;
}

.resource-link-card__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--hd-dark-blue, #002554);
  margin-bottom: 0.25rem;
}

.resource-link-card__desc {
  font-size: 0.8125rem;
  color: #6b7280;
  margin-bottom: 0.75rem;
  line-height: 1.45;
}

.resource-link-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--hd-discovery-blue, #003087);
  transition: gap 0.2s ease;
}

.resource-link-card:hover .resource-link-card__cta {
  gap: 0.5rem;
}

/* 자료실 다운로드 카드 (레거시) */
.download-card {
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.download-card:hover {
  border-color: var(--hd-discovery-blue);
  background-color: var(--hd-light-blue);
}

/* 폼 스타일 */
.form-input:focus {
  outline: none;
  border-color: var(--hd-discovery-blue);
  box-shadow: 0 0 0 3px rgba(0, 48, 135, 0.1);
}

/* 파일 드래그 앤 드롭 */
.file-drop-zone {
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.file-drop-zone.dragover {
  border-color: var(--hd-discovery-blue);
  background-color: var(--hd-light-blue);
}

/* 스크롤 애니메이션 */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* 오시는길 지도 */
.location-map-wrap {
  border-radius: 0.75rem;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  background: #f8fafc;
  min-height: 420px;
}

.location-map {
  width: 100%;
  height: 420px;
  touch-action: pan-x pan-y;
}

.location-map-wrap--ready .location-map {
  opacity: 1;
}

@media (min-width: 1024px) {
  .location-map {
    height: 480px;
  }

  .location-map-wrap {
    min-height: 480px;
  }
}

.map-fallback {
  min-height: 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 2rem;
  text-align: center;
}
