@charset "utf-8";
/* =====================================================================
   연혁(page/history.php)
   - 글꼴·여백·브레드크럼·등장 효과는 회사소개 스타일(sm-about.css)을 그대로 쓴다
   - 배치는 사업 영역과 같은 결: 화면 폭 가득한 회색 줄, 사진 알약, 들어오면 진해지는 큰 글자
   ===================================================================== */

/* 서브 상단 사진 배너·하위 메뉴 탭은 쓰지 않음 — 회사소개와 같이 헤더 바로 아래에서 첫 화면 시작 */
body:has(#sub-history) .sm-subhead { display: none; }
body:has(#sub-history) #container, body:has(#sub-history) #container_wr { background: var(--sm-white); }
body:has(#sub-history) #container { padding-top: 0; }

/* ---- 1. 첫 화면: 큰 영문 두 단어(아래 단어는 오른쪽으로 비껴), 오른쪽 아래 한 문장·소개 ---- */
.sm-hs-hero { padding: calc(var(--sm-hd-total) + 32px) var(--sm-ab-pad) 0; }
.sm-hs-hero-main { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 480px); gap: clamp(32px, 5vw, 96px); align-items: end; margin-top: clamp(40px, 6vw, 96px); }
.sm-hs-title { display: flex; flex-direction: column; margin: 0; font-family: var(--sm-font-display); font-size: clamp(72px, 13vw, 240px); font-weight: 700; line-height: .92; letter-spacing: -0.055em; color: var(--sm-ink); }
.sm-hs-w { display: block; padding-bottom: .04em; white-space: nowrap; } /* 칸이 좁아도 단어 중간(Stor/y)에서 줄바꿈되지 않게 */
.sm-hs-w + .sm-hs-w { padding-left: .6em; }
.sm-hs-hero-copy { padding-bottom: .5em; }
.sm-hs-hero-copy .sm-ab-hero-lead { margin: 0 0 16px; }
.sm-hs-hero-copy .sm-ab-text { margin: 0; }
.sm-ab-on .sm-hs-title { clip-path: inset(-.1em -.5em -.2em -.5em); }
.sm-ab-on .sm-hs-w { animation: sm-hs-up 1s cubic-bezier(.22, .8, .24, 1) both; }
.sm-ab-on .sm-hs-w + .sm-hs-w { animation-delay: .12s; }
.sm-ab-on .sm-hs-hero-copy { animation: sm-hs-fade 1s ease .6s both; }
@keyframes sm-hs-up { from { transform: translateY(110%); } to { transform: none; } }
@keyframes sm-hs-fade { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }

/* ---- 2. 연도별: 화면 폭 가득한 줄. 왼쪽 큰 연도는 구간 안에서 따라 내려옴 ---- */
.sm-hs-years { margin-top: clamp(64px, 7vw, 120px); }
.sm-hs-year { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 4vw, 80px); padding: clamp(48px, 6vw, 96px) var(--sm-ab-pad); border-bottom: 1px solid #dedede; }
.sm-hs-stick { position: static; } /* 연도 숫자는 스크롤해도 따라오지 않고 처음 자리에 둔다(사용자 요청) */
/* 연도 숫자: 연한 숫자 위에 같은 숫자 모양으로 자른 그해 사진을 겹치고, --fill 만큼 아래부터 보이게(스크립트가 스크롤로 정함) */
.sm-hs-num { position: relative; margin: 0; font-family: var(--sm-font-display); font-size: clamp(88px, 13vw, 240px); font-weight: 800; line-height: .9; letter-spacing: -0.05em; color: #e4dfd6; }
.sm-hs-num::after { content: attr(data-y); position: absolute; inset: 0; background: var(--img) center / cover no-repeat; -webkit-background-clip: text; background-clip: text; color: transparent; clip-path: inset(calc(100% - var(--fill, 100%)) 0 0 0); }

.sm-hs-sum { margin: .2em 0 0; font-size: clamp(24px, 2.4vw, 38px); font-weight: 700; line-height: 1.3; letter-spacing: -0.04em; color: var(--sm-ink); word-break: keep-all; }

.sm-hs-list { margin: clamp(32px, 3.4vw, 56px) 0 0; padding: 0; list-style: none; border-top: 1px solid #dedede; }
.sm-hs-list li { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 16px; align-items: start; padding: 22px 0; border-bottom: 1px solid #dedede; }
.sm-hs-list li:last-child { border-bottom: 0; }
.sm-hs-tag { justify-self: start; padding: 4px 12px; border: 1px solid #d6d6d6; border-radius: 999px; font-size: 13px; font-weight: 600; line-height: 1.4; color: var(--sm-ink-2); transition: color .3s ease, background-color .3s ease, border-color .3s ease; }
.sm-hs-list p { margin: 0; font-size: 18px; font-weight: 500; line-height: 1.6; letter-spacing: -0.02em; color: var(--sm-ink); word-break: keep-all; transition: transform .5s cubic-bezier(.22, .8, .24, 1); }
.sm-hs-list small { display: block; margin-top: 4px; font-size: 14px; font-weight: 400; color: var(--sm-ink-3); }
@media (hover: hover) {
    .sm-hs-list li:hover .sm-hs-tag { border-color: var(--sm-mango); background: var(--sm-mango); color: var(--sm-white); }
    .sm-hs-list li:hover p { transform: translateX(6px); }
}

/* 들어올 때: 일 목록이 차례로 올라옴 */
.sm-ab-on .sm-hs-sum, .sm-ab-on .sm-hs-list li { opacity: 0; transform: translateY(24px); transition: opacity .8s ease, transform .9s cubic-bezier(.22, .8, .24, 1); }
.sm-ab-on .sm-hs-year.is-in .sm-hs-sum, .sm-ab-on .sm-hs-year.is-in .sm-hs-list li { opacity: 1; transform: none; }
.sm-ab-on .sm-hs-list li:nth-child(1) { transition-delay: .15s; }
.sm-ab-on .sm-hs-list li:nth-child(2) { transition-delay: .25s; }
.sm-ab-on .sm-hs-list li:nth-child(3) { transition-delay: .35s; }
.sm-ab-on .sm-hs-list li:nth-child(4) { transition-delay: .45s; }

/* 1280px 이하: 큰 제목과 소개 글을 나란히 둘 폭이 안 돼(제목 칸이 Story 보다 좁아짐) 제목 아래로 소개 글을 내리고 오른쪽에 붙인다(사업 영역 첫 화면과 같은 배치) */
@media (max-width: 1280px) {
    .sm-hs-hero-main { grid-template-columns: minmax(0, 1fr); gap: clamp(40px, 5vw, 72px); }
    .sm-hs-title { row-gap: .08em; }
    .sm-hs-hero-copy { justify-self: end; width: 100%; max-width: 520px; padding-bottom: 0; }
}
@media (max-width: 1024px) {
    .sm-hs-year { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
}
@media (max-width: 768px) {
    .sm-hs-hero { padding-top: calc(var(--sm-hd-total) + 24px); }
    /* 제목 위(브레드크럼 아래)와 아래(소개 글 위) 간격을 56px 로 같게, 소개 글 아래(첫 연도 위: 56px + 연도 줄 위 여백 40px)는 96px — 사업 영역 모바일과 같은 간격 */
    .sm-hs-hero-main { margin-top: 56px; gap: 56px; }
    .sm-hs-title { font-size: 24vw; }
    .sm-hs-hero-copy { max-width: none; }
    .sm-hs-years { margin-top: 56px; }
    .sm-hs-year { grid-template-columns: minmax(0, 1fr); gap: 20px; padding-top: 40px; padding-bottom: 40px; }
    .sm-hs-stick { position: static; }
    .sm-hs-num { font-size: 30vw; }
    .sm-hs-list li { grid-template-columns: 64px minmax(0, 1fr); gap: 12px; padding: 18px 0; }
    .sm-hs-tag { padding: 3px 9px; font-size: 12px; }
    .sm-hs-list p { font-size: 16px; }
    .sm-hs-list small { font-size: 13px; }
}
@media (max-width: 319px) {
    .sm-hs-title { font-size: 77px; }
    .sm-hs-num { font-size: 96px; }
}
@media (prefers-reduced-motion: reduce) {
    .sm-hs-tag, .sm-hs-list p { transition: none; }
}
