/* ===== Reset ===== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

/* ===== 全站基本樣式 ===== */
body {
  font-family: system-ui, sans-serif;
  line-height: 1.6;
  background-color: #FAFBFC;
  color: #111;

  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ===== 容器 ===== */
.container {
  flex: 1;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 0 16px;
}

.card {
  background: #fff;
  padding: 24px;
  box-shadow: 0px 12px 18px -6px rgba(34, 56, 101, 0.04)
}

/* ===== Header ===== */
.site-header {
  background-color: #3FA7A1;
  padding: 14px 0;
  margin-bottom: 60px;
}

/* ===== Main + Aside 切版 ===== */
.content-wrapper {
  display: flex;
  gap: 24px;
  align-items: flex-start; /* 避免互相撐高 */
  padding-bottom: 40px;
}

/* ⭐ 這個超重要：允許 flex item 縮小 */
.content-wrapper > * {
  min-width: 0;
}

/* 主內容 */
main {
  flex: 2.5 1 0;
}

/* 側邊欄 */
aside {
  flex: 1 1 0;

  /* ⭐ 讓 widget 垂直排列 */
  display: flex;
  flex-direction: column;
  gap: 20px;

  /* ⭐ 防止長字串撐爆 */
  overflow-wrap: break-word;
  word-break: break-word;
}

/* ===== 手機版 ===== */
@media (max-width: 768px) {
  .content-wrapper {
    flex-direction: column;
  }
  aside {
    display: none;          /* 側邊欄隱藏 */
    flex: 0 0 0;            /* 避免占空間 */
    width: 0;
    height: 0;
    overflow: hidden;
  }
}

/* ===== Footer ===== */
.site-footer {
  background-color: #f1f1f1;
  color: #111;
  padding: 16px 0;
}