/* SynapMall — 아틀리에 스킨(단독 브랜드·인테리어 소품·라이프스타일). 마켓 스킨(skins/market/shop.css) 위에 얹는다.
   회반죽 벽 같은 분홍빛 회색 바탕, 검정 글자와 호두나무 갈색 하나, 각진 사진과 1px 테두리 단추, 모든 제목은 가운데.
   메인: 화면 끝까지 닿는 사진 배너 · 흰 띠 브랜드 이야기(가는 세로선) · 넘기는 진열 줄 · 가는 원 두 개의 사진 띠 · 엇갈린 기획전.
   클래스는 sm-at-*(메인 템플릿 skins/atelier/shop/index.html). */
:root {
  --sm-bg: #F1EBE6;
  --sm-surface: #FFFFFF;
  --sm-ink: #141210;
  --sm-text: #2E2925;
  --sm-text-2: #59514B;
  --sm-muted: #7D746D;
  --sm-faint: #A69D96;
  --sm-line: #E2D9D1;
  --sm-line-2: #C9BEB4;
  --sm-soft: #E6DED6;          /* 사진 바탕 */
  --sm-soft-2: #F8F5F2;
  --sm-free: #5F6B4E;
  --sm-accent: #4A3F37;
  --sm-accent-soft: #E9E1D9;
  --sm-radius: 0;
  --sm-radius-sm: 0;
  --sm-font: 'Noto Sans KR', 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Malgun Gothic', sans-serif;
  --bs-body-bg: var(--sm-bg);
  --bs-link-color-rgb: 20, 18, 16;

  --sm-at-stone: #E4DCD4;      /* 바닥글 */
  --sm-at-scrim: rgba(20, 16, 12, .34);
}
body { background: var(--sm-bg); letter-spacing: -0.01em; }
/* 화면 끝까지 닿는 사진(.sm-at-bleed = 100vw)이 스크롤바 폭만큼 가로 스크롤을 만들지 않게 — clip 은 스크롤 상자를 만들지 않아 sticky 머리말이 그대로 붙는다 */
html, body { overflow-x: clip; }
::selection { background: var(--sm-ink); color: var(--sm-bg); }
:focus-visible { outline-color: var(--sm-ink); }

/* ── 머리말 — 흰 한 줄, 로고 왼쪽 · 분류 가운데 · 아이콘 오른쪽 ── */
.sm-notice { background: var(--sm-ink); color: var(--sm-surface); letter-spacing: .02em; }
.sm-header { background: var(--sm-surface); border-bottom-color: transparent; }
.sm-header.is-scrolled { border-bottom-color: var(--sm-line); }
.sm-logo, .sm-logo:hover { font-weight: 700; font-size: 1.3rem; letter-spacing: .02em; text-transform: uppercase; color: var(--sm-ink); }
.sm-hd-line .sm-header-row { height: 76px; }
/* 가운데 — 넘칠 때도 앞이 잘리지 않게 양 끝 auto 여백으로(justify-content: center 는 넘치면 앞을 자른다) */
.sm-hd-line .sm-catbar > :first-child { margin-left: auto; }
.sm-hd-line .sm-catbar > :last-child { margin-right: auto; }
.sm-hd-line .sm-catbar a { height: 76px; font-size: .9rem; font-weight: 500; color: var(--sm-ink); }
.sm-catbar a.active::after { background: var(--sm-ink); height: 1px; }
.sm-catbar a:hover, .sm-util a:hover { color: var(--sm-muted); }
.sm-allcat-panel { border: 1px solid var(--sm-line); border-radius: 0; box-shadow: 0 18px 40px -20px rgba(20, 16, 12, .3); }
.sm-hd-searchpanel { background: var(--sm-surface); }

/* ── 버튼·입력 — 네모, 1px 테두리 ────────────────────── */
.btn, .btn-lg, .btn-sm { --bs-btn-border-radius: 0; }
.btn-lg { --bs-btn-padding-x: 2rem; --bs-btn-font-weight: 500; }
.btn-dark { --bs-btn-bg: var(--sm-ink); --bs-btn-border-color: var(--sm-ink); }
.form-control, .form-select { border-radius: 0; background-color: var(--sm-surface); }
.form-control:focus, .form-select:focus { border-color: var(--sm-ink); box-shadow: none; }
.sm-chip { border-radius: 0; background: transparent; }
.sm-chip.active { background: var(--sm-ink); border-color: var(--sm-ink); }
.sm-box, .sm-sum { background: var(--sm-surface); border-radius: 0; }
.sm-at-line { display: inline-flex; align-items: center; justify-content: center; min-width: 250px; min-height: 52px; padding: 0 28px; border: 1px solid var(--sm-text-2);
  background: transparent; color: var(--sm-ink); font-size: .92rem; font-weight: 700; letter-spacing: .04em; transition: background-color .25s, color .25s, border-color .25s; }
.sm-at-line:hover { background: var(--sm-ink); border-color: var(--sm-ink); color: var(--sm-surface); }
.sm-at-line.is-light { border-color: rgba(255, 255, 255, .85); color: #fff; }
.sm-at-line.is-light:hover { background: #fff; border-color: #fff; color: var(--sm-ink); }
.sm-at-more { text-align: center; margin-top: 48px; }

/* ── 섹션 제목 — 가운데, 굵은 제목 + 회색 한 줄 ────────── */
.sm-section { margin-top: 120px; }
.sm-at-head { text-align: center; margin-bottom: 44px; }
.sm-at-head h2 { margin: 0; font-size: 2.1rem; font-weight: 700; letter-spacing: -0.02em; color: var(--sm-ink); }
.sm-at-head p { margin: 10px 0 0; color: var(--sm-text-2); font-size: .95rem; }
.sm-rail-nav.center { justify-content: center; margin-top: 28px; gap: 8px; }
.sm-rail-nav button { width: 44px; height: 44px; border-radius: 0; border-color: var(--sm-line-2); background: transparent; }
.sm-rail-nav button:hover { border-color: var(--sm-ink); background: var(--sm-surface); }

/* ── 화면 끝까지 닿는 칸 — 가운데 맞춘 container 안에서 화면 폭으로 편다 ── */
.sm-at-bleed { position: relative; width: 100vw; margin-left: calc(50% - 50vw); }

/* ── 메인 배너 — 사진 위 가운데 큰 제목 · 글자 간격 넓힌 낱말 · 테두리 단추 ─── */
.sm-slider { border-radius: 0; }
.sm-at-hero { display: flex; align-items: center; justify-content: center; min-height: clamp(520px, calc(100svh - 120px), 820px); margin-top: -24px;
  padding: 96px 24px; overflow: hidden; background: var(--sm-soft); color: #fff; text-align: center; }
.sm-at-hero-img { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--sm-faint); font-size: 6rem; }
.sm-at-hero-img img { width: 100%; height: 100%; object-fit: cover; }
.sm-at-hero-img::after { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse 60% 55% at 50% 52%, rgba(20, 16, 12, .42), rgba(20, 16, 12, .16)); }   /* 글이 놓이는 가운데만 더 어둡게 */
.sm-at-hero-copy { position: relative; z-index: 1; max-width: 820px; }
.sm-at-hero h1 { margin: 0; font-size: clamp(2.6rem, 6vw, 4.6rem); font-weight: 700; letter-spacing: -0.01em; line-height: 1.12; white-space: pre-line;
  text-shadow: 0 2px 24px rgba(20, 16, 12, .18); }
.sm-at-word { margin-top: 14px; font-size: 1.05rem; font-weight: 700; letter-spacing: .4em; text-transform: uppercase; color: rgba(255, 255, 255, .78); padding-left: .4em; }
.sm-at-hero p { max-width: 460px; margin: 22px auto 36px; font-size: .98rem; line-height: 1.75; color: rgba(255, 255, 255, .9); white-space: pre-line; }

/* ── 브랜드 이야기 — 흰 띠(화면 끝까지) 가운데, 가는 세로선 ─── */
.sm-at-story { padding: 96px 16px 100px; text-align: center; background: var(--sm-surface); box-shadow: 0 0 0 100vmax var(--sm-surface); clip-path: inset(0 -100vmax); }
.sm-hero + .sm-at-story, .sm-at-hero + .sm-at-story, .sm-slider + .sm-at-story { margin-top: 0; }
.sm-at-story h2 { margin: 0; font-size: 2.1rem; font-weight: 700; letter-spacing: .01em; color: var(--sm-ink); }
.sm-at-rule { display: block; width: 1px; height: 60px; margin: 18px auto 28px; background: var(--sm-ink); }
.sm-at-lede { max-width: 560px; margin: 0 auto; font-size: clamp(1.45rem, 2.4vw, 2.05rem); font-weight: 300; line-height: 1.55; letter-spacing: -0.03em; color: var(--sm-ink); }
.sm-at-story .sm-at-more { margin-top: 44px; }

/* ── 상품 카드 — 각진 사진, 이름 줄 오른쪽에 가는 선 아이콘 ─── */
.sm-grid { gap: 52px 20px; }
.sm-rail { grid-auto-columns: calc((100% - 3 * 20px) / 4); gap: 20px; }
.sm-thumb { aspect-ratio: 1 / 1; border-radius: 0; background: var(--sm-soft); }
.sm-noimg { background: transparent; color: var(--sm-faint); }
.sm-rank, .sm-rank.top { min-width: 0; height: auto; padding: 6px 10px; background: var(--sm-surface); color: var(--sm-ink); font-size: .78rem; font-weight: 700; letter-spacing: .06em; }
.sm-rank.top { background: var(--sm-ink); color: var(--sm-surface); }
.sm-at-row { display: flex; align-items: flex-start; gap: 8px; padding-top: 14px; }
.sm-at-row .sm-card-body { flex: 1 1 auto; min-width: 0; padding-top: 0; gap: 6px; }
.sm-card-body:hover .sm-name { text-decoration: underline; text-underline-offset: 4px; }
.sm-name { font-size: 1.02rem; font-weight: 400; color: var(--sm-ink); }
.sm-price b { font-size: .95rem; font-weight: 400; color: var(--sm-muted); }
.sm-price b small { font-weight: 400; }
.sm-price em { font-size: .95rem; font-weight: 500; color: var(--sm-ink); }
.sm-at-acts { display: flex; flex-shrink: 0; margin: -10px -10px 0 0; }
.sm-at-acts .sm-card-wish, .sm-at-add { position: static; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0;
  border: 0; background: none; color: var(--sm-text-2); font-size: 1.1rem; filter: none; }
.sm-at-acts .sm-card-wish:hover, .sm-at-add:hover { color: var(--sm-ink); }
.sm-at-acts .sm-card-wish.on { color: var(--sm-accent); }
.sm-tags span { border-radius: 0; }

/* ── 사진 띠 — 화면 끝까지 닿는 사진, 가는 원 두 개 ─── */
.sm-at-band { display: flex; align-items: center; justify-content: center; min-height: 600px; padding: 80px 24px; overflow: hidden; background: var(--sm-soft); color: #fff; text-align: center; }
.sm-at-band-img { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--sm-faint); font-size: 6rem; }
.sm-at-band-img img { width: 100%; height: 100%; object-fit: cover; }
.sm-at-band-img::after { content: ''; position: absolute; inset: 0; background: var(--sm-at-scrim); }
.sm-at-rings { position: absolute; left: 50%; top: 50%; width: min(460px, 86vw); height: auto; translate: -50% -50%; overflow: visible; }
.sm-at-rings circle { fill: none; stroke: rgba(255, 255, 255, .8); stroke-width: 1; vector-effect: non-scaling-stroke; stroke-dasharray: 1; }
.sm-at-band-copy { position: relative; z-index: 1; max-width: 340px; }
.sm-at-band h2 { margin: 0; font-size: 2.1rem; font-weight: 500; line-height: 1.35; letter-spacing: -0.03em; color: #fff; }
.sm-at-band p { margin: 14px 0 0; font-size: .92rem; color: rgba(255, 255, 255, .88); }

/* ── 기획전 — 두 줄, 오른쪽 줄은 아래로 엇갈려 ────────── */
.sm-at-events .sm-event-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; max-width: 1000px; margin: 0 auto; }
.sm-at-events .sm-event { margin-bottom: 56px; gap: 16px; }
.sm-at-events .sm-event:nth-child(2n) { margin-top: 64px; margin-bottom: -8px; }
.sm-event-img { border-radius: 0; aspect-ratio: 1 / 1; background: var(--sm-soft); }
.sm-event-body { text-align: center; }
.sm-event-body b { font-weight: 500; font-size: 1.1rem; }
.sm-event-date { color: var(--sm-muted); font-size: .82rem; }
.sm-at-events .sm-at-more { margin-top: 32px; }

/* ── 상품 상세·목록 ───────────────────────────────────── */
.sm-gallery #mainImg { border-radius: 0; }
.sm-thumb-sm { border-radius: 0; }
.sm-tabs button.active { border-top-color: var(--sm-ink); }
.sm-listbar { border-bottom-color: var(--sm-line-2); }

/* ── 바닥글 ───────────────────────────────────────────── */
.sm-footer { background: var(--sm-at-stone); border-top: 0; margin-top: 40px; }
.sm-footer-links, .sm-footer-note { border-color: var(--sm-line-2); }
.sm-footer .cs { font-weight: 500; font-size: 1.5rem; }

/* ── 반응형 ───────────────────────────────────────────── */
@media (max-width: 991px) {
  .sm-hd-line .sm-catbar > :first-child { margin-left: 0; }
  .sm-rail { grid-auto-columns: calc((100% - 2 * 20px) / 3); }
  .sm-at-band { min-height: 520px; }
}
@media (max-width: 767px) {
  .sm-section { margin-top: 80px; }
  .sm-hd-line .sm-catbar a { height: 44px; }
  .sm-at-head { margin-bottom: 28px; }
  .sm-at-head h2, .sm-at-story h2 { font-size: 1.6rem; }
  .sm-at-line { min-width: 200px; min-height: 48px; }
  .sm-at-more { margin-top: 36px; }
  .sm-at-hero { min-height: 72svh; margin-top: -12px; padding: 72px 20px; }
  .sm-at-hero h1 { font-size: 2.3rem; }
  .sm-at-word { font-size: .9rem; letter-spacing: .32em; }
  .sm-at-hero p { margin: 16px auto 28px; font-size: .92rem; }
  .sm-at-story { padding: 64px 8px 68px; }
  .sm-at-rule { height: 44px; margin: 14px auto 22px; }
  .sm-grid { gap: 36px 12px; }
  .sm-rail { grid-auto-columns: 62%; gap: 12px; }
  .sm-name { font-size: .92rem; }
  .sm-at-band { min-height: 440px; }
  .sm-at-band h2 { font-size: 1.6rem; }
  .sm-at-events .sm-event-grid { grid-template-columns: 1fr; }
  .sm-at-events .sm-event, .sm-at-events .sm-event:nth-child(2n) { margin: 0 0 40px; }
}

/* ── 움직임(아틀리에) — 조용하고 느리게. 배너 사진은 천천히 물러나 자리 잡고, 원은 나타날 때 그려진다 ─── */
:root { --sm-dur: .9s; --sm-rise: 22px; --sm-stagger: 90ms; }
@media (prefers-reduced-motion: no-preference) {
  @keyframes at-rise { from { opacity: 0; translate: 0 22px; } to { opacity: 1; translate: none; } }
  @keyframes at-settle { from { scale: 1.08; } to { scale: 1; } }
  .sm-at-hero-copy > * { animation: at-rise 1s var(--sm-ease) both; }
  .sm-at-hero-copy > :nth-child(2) { animation-delay: .12s; }
  .sm-at-hero-copy > :nth-child(3) { animation-delay: .24s; }
  .sm-at-hero-copy > :nth-child(4) { animation-delay: .36s; }
  .sm-at-hero-img img { animation: at-settle 2.6s cubic-bezier(.2, .7, .2, 1) both; }
  .sm-at-band-img img { height: calc(100% + 60px); flex-shrink: 0; translate: 0 calc((var(--sm-p, .5) - .5) * -60px); }   /* 위아래 30px 여유 — 움직여도 가장자리가 드러나지 않게 */
  /* 원 — 스크롤로 나타날 때만 그린다(첫 화면에 이미 보이면 처음부터 그려져 있다) */
  .sm-at-band.sm-reveal .sm-at-rings circle { stroke-dashoffset: 1; transition: stroke-dashoffset 2.2s cubic-bezier(.4, 0, .2, 1) .2s; }
  .sm-at-band.sm-reveal .sm-at-rings circle + circle { transition-delay: .5s; }
  .sm-at-band.sm-reveal.is-in .sm-at-rings circle { stroke-dashoffset: 0; }
  .sm-thumb img, .sm-event-img img { transition: scale .9s var(--sm-ease); }
  .sm-card:hover .sm-thumb img, .sm-event:hover .sm-event-img img { transform: none; scale: 1.04; }
}
