/* ==========================================================================
   main.css — 신원스틸(주) 메인 페이지 전용 스타일
   index.html 전용이며 common.css 이후에 로드됩니다.
   ========================================================================== */

/* --------------------------------------------------------------------------
   공통 레이블 스타일
   -------------------------------------------------------------------------- */
.label {
  display: inline-block;
  font-size: var(--font-size-label);
  font-weight: var(--font-weight-medium);
  letter-spacing: var(--letter-spacing-label);
  text-transform: uppercase;
  color: var(--color-primary);
}

/* --------------------------------------------------------------------------
   1. 히어로 섹션
   -------------------------------------------------------------------------- */
.hero {
  height: 100vh;
  min-height: 700px;
  background-color: #060c18;
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
}

/* 격자 패턴 오버레이 */
.hero__bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(27, 100, 218, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(27, 100, 218, 0.07) 1px, transparent 1px);
  background-size: 64px 64px;
  z-index: 1;
}

/* 좌측 블루 세로 액센트 라인 */
.hero::before {
  content: '';
  position: absolute;
  left: 0;
  top: 15%;
  bottom: 15%;
  width: 3px;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    var(--color-primary) 30%,
    var(--color-primary) 70%,
    transparent 100%
  );
  box-shadow: 0 0 20px rgba(27, 100, 218, 0.6);
  z-index: 2;
}

/* 우측 원형 장식 */
.hero::after {
  content: '';
  position: absolute;
  right: 8%;
  top: 50%;
  transform: translateY(-50%);
  width: 520px;
  height: 520px;
  border-radius: 50%;
  border: 1px solid rgba(27, 100, 218, 0.18);
  box-shadow:
    0 0 80px rgba(27, 100, 218, 0.12),
    inset 0 0 80px rgba(27, 100, 218, 0.06);
  z-index: 1;
  pointer-events: none;
}

/* 히어로 콘텐츠 */
.hero__content {
  position: relative;
  z-index: 3;
  padding-top: calc(var(--gnb-height) + var(--util-bar-height));
  padding-left: 60px;
  max-width: 760px;
}

/* 히어로 레이블 */
.hero__content .label {
  color: rgba(126, 176, 255, 0.85);
  margin-bottom: 28px;
  display: block;
  position: relative;
  padding-left: 32px;
}

/* 레이블 왼쪽 선 */
.hero__content .label::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 2px;
  background-color: var(--color-primary);
}

/* 히어로 h1 */
.hero__content h1 {
  font-size: var(--font-size-h1);
  font-weight: var(--font-weight-bold);
  color: var(--color-white);
  line-height: 1.2;
  margin-bottom: 24px;
  letter-spacing: -1px;
}

/* 강조 텍스트 — 블루 그라디언트 */
.hero__content h1 em {
  font-style: normal;
  background: linear-gradient(135deg, #7EB0FF 0%, #4D8EF7 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 히어로 설명 */
.hero__content p {
  color: rgba(255, 255, 255, 0.65);
  font-size: 18px;
  line-height: var(--line-height-body);
  margin-bottom: 44px;
  max-width: 480px;
}

/* 히어로 버튼 그룹 */
.hero__btns {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* 히어로 아웃라인 버튼 */
.hero__btns .btn-outline {
  background-color: transparent;
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.4);
}

.hero__btns .btn-outline:hover {
  background-color: var(--color-white);
  color: var(--color-dark);
  border-color: var(--color-white);
}

/* 스크롤 화살표 */
.hero__scroll-arrow {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: opacity var(--transition-normal);
}

.hero__scroll-arrow:hover {
  opacity: 0.7;
}

.hero__scroll-arrow span {
  font-size: 11px;
  font-weight: var(--font-weight-medium);
  letter-spacing: 3px;
  color: rgba(255, 255, 255, 0.45);
  text-transform: uppercase;
}

/* 화살표 애니메이션 */
.arrow-anim {
  width: 1px;
  height: 48px;
  background: linear-gradient(
    to bottom,
    rgba(27, 100, 218, 0.6),
    transparent
  );
  position: relative;
  overflow: hidden;
}

.arrow-anim::after {
  content: '';
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to bottom,
    transparent,
    rgba(126, 176, 255, 0.9),
    transparent
  );
  animation: scrollArrow 1.8s ease-in-out infinite;
}

@keyframes scrollArrow {
  0%   { top: -100%; }
  100% { top: 100%; }
}

/* --------------------------------------------------------------------------
   2. 수치(통계) 섹션
   -------------------------------------------------------------------------- */
.stats {
  padding: 0;
  background-color: var(--color-white);
  position: relative;
  border-top: 3px solid var(--color-primary);
}

.stats .container {
  border-bottom: 1px solid var(--color-border);
}

.stats__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  text-align: center;
}

/* 구분선 (세로) */
.stats__item {
  position: relative;
  padding: 56px 20px;
  transition: background-color var(--transition-normal);
}

.stats__item:hover {
  background-color: rgba(27, 100, 218, 0.03);
}

.stats__item:not(:last-child)::after {
  content: '';
  position: absolute;
  right: 0;
  top: 30%;
  height: 40%;
  width: 1px;
  background-color: var(--color-border);
}

/* 숫자 */
.stats__item strong {
  display: block;
  font-size: 52px;
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
  line-height: 1;
  margin-bottom: 12px;
  letter-spacing: -2px;
}

/* 숫자 단위 */
.stats__item strong span {
  font-size: 30px;
  font-weight: var(--font-weight-semibold);
  letter-spacing: 0;
}

/* 설명 레이블 */
.stats__item p {
  font-size: 14px;
  color: var(--color-gray);
  font-weight: var(--font-weight-medium);
  margin: 0;
  letter-spacing: 0.3px;
}

/* --------------------------------------------------------------------------
   3. 회사소개 섹션 (2단 레이아웃)
   -------------------------------------------------------------------------- */
.about-section {
  background-color: var(--color-white);
  padding: var(--section-padding) 0;
  position: relative;
  overflow: hidden;
}

/* 배경 장식 원 */
.about-section::before {
  content: '';
  position: absolute;
  right: -120px;
  top: -120px;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  border: 1px solid rgba(27, 100, 218, 0.07);
  pointer-events: none;
}

/* 공통 2단 레이아웃 */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

/* 역순 2단 (이미지 좌, 텍스트 우) */
.two-col--reverse {
  direction: rtl;
}

.two-col--reverse > * {
  direction: ltr;
}

/* 텍스트 영역 */
.two-col__text .label {
  display: block;
  margin-bottom: 16px;
}

.two-col__text h2 {
  font-size: var(--font-size-h2);
  font-weight: var(--font-weight-bold);
  color: var(--color-dark);
  line-height: 1.3;
  margin-bottom: 24px;
  letter-spacing: -0.5px;
}

.two-col__text p {
  font-size: var(--font-size-body);
  color: var(--color-gray);
  line-height: var(--line-height-body);
  margin-bottom: 32px;
}

/* 텍스트 링크 */
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: var(--font-weight-medium);
  color: var(--color-primary);
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(27, 100, 218, 0.3);
  transition: gap var(--transition-fast),
              border-color var(--transition-fast),
              color var(--transition-fast);
}

.text-link:hover {
  gap: 14px;
  border-color: var(--color-primary);
  color: var(--color-primary-dark);
}

/* 이미지 플레이스홀더 */
.img-placeholder {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, #F2F4F6 0%, #E9EDF2 100%);
  border-radius: var(--border-radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border);
  position: relative;
  overflow: hidden;
}

/* 플레이스홀더 패턴 */
.img-placeholder::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 20px,
      rgba(27, 100, 218, 0.03) 20px,
      rgba(27, 100, 218, 0.03) 21px
    );
}

.img-placeholder::after {
  content: '이미지 영역';
  color: var(--color-gray-light);
  font-size: 13px;
  font-weight: var(--font-weight-medium);
  letter-spacing: 1px;
  position: relative;
  z-index: 1;
}

/* --------------------------------------------------------------------------
   4. 경영이념 섹션 (블루 배경 풀 와이드)
   -------------------------------------------------------------------------- */
.ideology-section {
  background: linear-gradient(135deg, #1243a8 0%, var(--color-primary) 50%, #1a5bd4 100%);
  padding: var(--section-padding) 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* 배경 격자 */
.ideology-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

/* 우측 원형 장식 */
.ideology-section::after {
  content: '';
  position: absolute;
  right: -100px;
  bottom: -100px;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  pointer-events: none;
}

/* 흰색 레이블 변형 */
.label--white {
  color: rgba(255, 255, 255, 0.75);
  display: block;
  margin-bottom: 16px;
}

.ideology-section h2 {
  font-size: var(--font-size-h2);
  font-weight: var(--font-weight-bold);
  color: var(--color-white);
  margin-bottom: 16px;
  position: relative;
  z-index: 1;
  letter-spacing: -0.5px;
}

.ideology-section > .container > p {
  color: rgba(255, 255, 255, 0.75);
  font-size: 17px;
  line-height: var(--line-height-body);
  max-width: 560px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

/* 경영이념 카드 그리드 */
.ideology-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-top: 64px;
  position: relative;
  z-index: 1;
}

/* 경영이념 개별 카드 */
.ideology-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--border-radius-lg);
  padding: 44px 36px;
  transition: background-color var(--transition-normal),
              transform var(--transition-normal),
              box-shadow var(--transition-normal);
}

.ideology-card:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* 아이콘 (SVG) */
.ideology-card__icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  padding: 12px;
  color: rgba(255, 255, 255, 0.95);
}

.ideology-card__icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.ideology-card h3 {
  font-size: 20px;
  font-weight: var(--font-weight-semibold);
  color: var(--color-white);
  margin-bottom: 14px;
  letter-spacing: -0.3px;
}

.ideology-card p {
  font-size: var(--font-size-small);
  color: rgba(255, 255, 255, 0.72);
  line-height: var(--line-height-body);
  margin: 0;
}

/* --------------------------------------------------------------------------
   5. 취급강종 섹션
   -------------------------------------------------------------------------- */
.grades-section {
  background-color: var(--color-bg-light);
  padding: var(--section-padding) 0;
  position: relative;
}

/* 섹션 헤더 영역 */
.grades-section .label,
.news-section .label {
  display: block;
  margin-bottom: 12px;
}

.grades-section h2,
.news-section h2 {
  font-size: var(--font-size-h2);
  font-weight: var(--font-weight-bold);
  color: var(--color-dark);
  margin-bottom: 0;
  letter-spacing: -0.5px;
}

/* 강종 헤더 레이아웃 */
.grades-section > .container > .label,
.grades-section > .container > h2 {
  text-align: left;
}

/* 강종 그리드 */
.grades-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 52px;
}

/* 강종 카드 */
.grade-card {
  background-color: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--border-radius-lg);
  padding: 32px 28px;
  position: relative;
  overflow: hidden;
  transition: box-shadow var(--transition-normal),
              transform var(--transition-normal),
              border-color var(--transition-normal);
}

/* 카드 상단 블루 선 */
.grade-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--color-primary), rgba(27, 100, 218, 0.3));
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.grade-card:hover {
  box-shadow: 0 8px 30px rgba(27, 100, 218, 0.12);
  transform: translateY(-4px);
  border-color: rgba(27, 100, 218, 0.2);
}

.grade-card:hover::before {
  opacity: 1;
}

/* 강종 이름 (대형) */
.grade-card__name {
  font-size: 26px;
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
  margin-bottom: 4px;
  letter-spacing: -0.5px;
}

/* 규격명 */
.grade-card__spec {
  font-size: 13px;
  color: var(--color-gray);
  margin-bottom: 16px;
  font-weight: var(--font-weight-medium);
}

/* 구분선 */
.grade-card__divider {
  width: 36px;
  height: 2px;
  background-color: var(--color-primary);
  border-radius: 1px;
  margin-bottom: 16px;
  opacity: 0.35;
}

/* 용도 설명 */
.grade-card__desc {
  font-size: var(--font-size-small);
  color: var(--color-gray);
  line-height: 1.65;
  margin-bottom: 20px;
}

/* 태그 목록 */
.grade-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.grade-card__tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: var(--font-weight-medium);
  border-radius: var(--border-radius-pill);
  background-color: rgba(27, 100, 218, 0.07);
  color: var(--color-primary);
  border: 1px solid rgba(27, 100, 218, 0.12);
}

/* --------------------------------------------------------------------------
   5-1. 메인 FACILITY 섹션 버튼 (다크 배경 위 아웃라인 버튼)
   -------------------------------------------------------------------------- */
.facility-section-new .btn-outline {
  background-color: transparent !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
}

.facility-section-new .btn-outline:hover {
  background-color: #ffffff !important;
  color: var(--color-dark) !important;
  border-color: #ffffff !important;
}

/* --------------------------------------------------------------------------
   6. 생산설비 섹션
   -------------------------------------------------------------------------- */
.facility-section {
  background-color: var(--color-white);
  padding: var(--section-padding) 0;
  position: relative;
  overflow: hidden;
}

.facility-section::before {
  content: '';
  position: absolute;
  left: -100px;
  bottom: -100px;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  border: 1px solid rgba(27, 100, 218, 0.06);
  pointer-events: none;
}

/* 설비 목록 */
.facility-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 32px;
}

.facility-list li {
  position: relative;
  padding: 16px 20px 16px 20px;
  font-size: var(--font-size-small);
  color: var(--color-gray);
  line-height: 1.6;
  background-color: var(--color-bg-light);
  border-radius: var(--border-radius-md);
  border-left: 3px solid var(--color-primary);
  transition: background-color var(--transition-fast);
}

.facility-list li:hover {
  background-color: rgba(27, 100, 218, 0.05);
}

/* 설비 이름 강조 */
.facility-list li strong {
  color: var(--color-dark);
  font-weight: var(--font-weight-semibold);
  display: block;
  margin-bottom: 4px;
}

/* --------------------------------------------------------------------------
   7. 언론 뉴스 섹션
   -------------------------------------------------------------------------- */
.news-section {
  background-color: var(--color-bg-light);
  padding: var(--section-padding) 0;
}

/* 뉴스 그리드 */
.news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 52px;
}

/* 뉴스 카드 */
.news-card {
  background-color: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--border-radius-lg);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--transition-normal),
              transform var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.news-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--color-primary), rgba(27, 100, 218, 0.3));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-normal);
}

.news-card:hover {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
  transform: translateY(-4px);
}

.news-card:hover::after {
  transform: scaleX(1);
}

/* 메타 (날짜 + 출처) */
.news-card__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.news-card__date {
  font-size: 12px;
  color: var(--color-gray-light);
  font-weight: var(--font-weight-medium);
}

.news-card__source {
  font-size: 12px;
  font-weight: var(--font-weight-semibold);
  color: var(--color-primary);
  background-color: rgba(27, 100, 218, 0.08);
  padding: 3px 10px;
  border-radius: var(--border-radius-pill);
}

/* 기사 제목 */
.news-card h3 {
  font-size: 16px;
  font-weight: var(--font-weight-semibold);
  color: var(--color-dark);
  line-height: 1.55;
  margin-bottom: 24px;
  flex: 1;
}

/* 기사 링크 */
.news-card .text-link {
  margin-top: auto;
}

/* --------------------------------------------------------------------------
   8. CTA + 지도 섹션
   -------------------------------------------------------------------------- */
.cta-section {
  background-color: var(--color-white);
  padding: var(--section-padding) 0;
}

/* 지도 플레이스홀더 */
.map-placeholder {
  width: 100%;
  height: 340px;
  background: linear-gradient(135deg, #F2F4F6 0%, #E9EDF2 100%);
  border-radius: var(--border-radius-lg);
  border: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.map-placeholder::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(27, 100, 218, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(27, 100, 218, 0.05) 1px, transparent 1px);
  background-size: 40px 40px;
}

.map-placeholder p {
  color: var(--color-gray-light);
  font-size: 14px;
  line-height: 1.6;
  margin: 0;
  position: relative;
  z-index: 1;
}

/* --------------------------------------------------------------------------
   반응형 — 태블릿 (768px ~ 1023px)
   -------------------------------------------------------------------------- */
@media (max-width: 1023px) {
  /* 히어로 */
  .hero__content {
    padding-left: 40px;
    max-width: 600px;
  }

  .hero__content h1 {
    font-size: 42px;
  }

  /* 우측 원 숨김 */
  .hero::after {
    width: 320px;
    height: 320px;
    right: 2%;
  }

  /* 수치 섹션 2열 */
  .stats__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats__item:nth-child(2)::after {
    display: none;
  }

  /* 2단 레이아웃 → 1단 */
  .two-col {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .two-col--reverse {
    direction: ltr;
  }

  /* 경영이념 카드 */
  .ideology-cards {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }

  /* 강종 그리드 2열 */
  .grades-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* 뉴스 그리드 */
  .news-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* --------------------------------------------------------------------------
   반응형 — 모바일 (~767px)
   -------------------------------------------------------------------------- */
@media (max-width: 767px) {
  /* 히어로 */
  .hero {
    min-height: 600px;
  }

  .hero::after {
    display: none;
  }

  .hero__content {
    padding-left: 24px;
    padding-right: 24px;
    padding-top: var(--gnb-height);
  }

  .hero__content h1 {
    font-size: 34px;
    letter-spacing: -0.5px;
  }

  .hero__content p {
    font-size: 16px;
  }

  .hero__btns {
    flex-direction: column;
    align-items: stretch;
  }

  .hero__btns .btn-primary,
  .hero__btns .btn-outline,
  .hero__btns .btn-outline-dark {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  /* 스크롤 화살표 숨김 */
  .hero__scroll-arrow {
    display: none;
  }

  /* 수치 섹션 */
  .stats__item {
    padding: 40px 16px;
  }

  .stats__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats__item strong {
    font-size: 40px;
  }

  .stats__item::after {
    display: none;
  }

  /* 경영이념 카드 1열 */
  .ideology-cards {
    grid-template-columns: 1fr;
    gap: 16px;
    margin-top: 40px;
  }

  .ideology-section h2 {
    font-size: 28px;
  }

  .ideology-card {
    padding: 32px 24px;
  }

  /* 강종 그리드 1열 */
  .grades-grid {
    grid-template-columns: 1fr;
  }

  /* 뉴스 그리드 1열 */
  .news-grid {
    grid-template-columns: 1fr;
  }

  /* 2단 제목 크기 축소 */
  .two-col__text h2 {
    font-size: 28px;
  }
}
