/* 모던 CSS 리셋 — 호반써밋 홈페이지 */
/* 출처: Josh Comeau modern reset + 프로젝트 커스텀 */

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

* {
  margin: 0;
  padding: 0;
}

html {
  /* 스크롤 행동 */
  scroll-behavior: smooth;
  /* 폰트 크기 기준 16px */
  font-size: 16px;
  /* iOS 텍스트 크기 자동 조정 방지 */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  /* 기본 폰트 */
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background-color: var(--color-surface);
  /* 가로 스크롤 방지 */
  overflow-x: hidden;
  /* 폰트 렌더링 최적화 */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* ── 미디어 기본값 ── */
img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

img, video {
  height: auto;
}

/* ── 폼 요소 ── */
input, button, textarea, select {
  font: inherit;
}

textarea {
  resize: vertical;
}

/* ── 링크 ── */
a {
  color: inherit;
  text-decoration: none;
}

/* ── 목록 ── */
ul, ol {
  list-style: none;
}

/* ── 제목 ── */
h1, h2, h3, h4, h5, h6 {
  line-height: var(--leading-tight);
  font-weight: var(--font-bold);
  letter-spacing: var(--tracking-tight);
}

/* ── 인용 ── */
blockquote, q {
  quotes: none;
}

blockquote::before, blockquote::after,
q::before, q::after {
  content: '';
}

/* ── 테이블 ── */
table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* ── 버튼 기본 리셋 ── */
button {
  cursor: pointer;
  border: none;
  background: none;
  -webkit-appearance: none;
  appearance: none;
}

/* ── 포커스 가시화 (접근성) ── */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* 마우스 사용자는 포커스 링 숨김 */
:focus:not(:focus-visible) {
  outline: none;
}

/* ── 터치 타겟 최소 크기 보장 ── */
button, a, [role="button"], input[type="checkbox"], input[type="radio"] {
  min-height: 44px;
  min-width: 44px;
}

/* 인라인 요소는 예외 */
a:not([class]) {
  min-height: unset;
  min-width: unset;
}

/* ── 선택 색상 ── */
::selection {
  background-color: var(--color-primary);
  color: #1a1d23;
}

/* ── 수직 오버플로 텍스트 ── */
p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
  word-break: keep-all;
}

/* ── SVG 기본 채움 ── */
svg {
  fill: currentColor;
}

/* ── 숨김 유틸 ── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border-width: 0;
}

/* ── 애니메이션 감소 설정 존중 ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
