/**
 * CSS Reset
 * 統一各瀏覽器預設樣式
 */

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

/* 移除預設 margin 和 padding */
* {
  margin: 0;
  padding: 0;
}

/* 設定根元素 */
html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

/* Body 預設樣式 */
body {
  min-height: 100vh;
  line-height: var(--line-height-normal, 1.5);
  font-family: var(--font-family-base, 'Noto Sans TC', sans-serif);
  color: var(--color-gray-900, #333333);
  background-color: var(--color-bg-light, #F5F5F5);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* 圖片和媒體 */
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* 移除列表樣式 */
ul,
ol {
  list-style: none;
}

/* 連結預設樣式 */
a {
  color: inherit;
  text-decoration: none;
}

/* 按鈕預設樣式 */
button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

/* 輸入框預設樣式 */
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

/* 移除輸入框外框 */
input:focus,
textarea:focus,
select:focus,
button:focus {
  outline: none;
}

/* 表格 */
table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* 標題 */
h1, h2, h3, h4, h5, h6 {
  font-weight: var(--font-weight-bold, 700);
  line-height: var(--line-height-tight, 1.25);
}

/* 段落 */
p {
  line-height: var(--line-height-relaxed, 1.75);
}

/* 強調文字 */
strong, b {
  font-weight: var(--font-weight-bold, 700);
}

/* 隱藏元素 */
[hidden] {
  display: none !important;
}

/* 無障礙：僅供螢幕閱讀器 */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
