body {
  background: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Noto Sans TC', 'Poppins', Arial, sans-serif;
  color: #1d1d1f;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-weight: 400;
  line-height: 1.47059;
  letter-spacing: -0.022em;
}
.navbar {
  background: rgba(255, 255, 255, 0.8) !important;
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  box-shadow: none !important;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: 0;
  padding-top: 0.875rem;
  padding-bottom: 0.875rem;
}
.navbar-brand {
  font-weight: 600;
  font-size: 1.375rem;
  letter-spacing: -0.022em;
  color: #1d1d1f !important;
  display: flex;
  align-items: center;
}
.navbar-nav .nav-link {
  color: #6e6e73 !important;
  font-size: 1.0625rem;
  margin-left: 1.5rem;
  margin-right: 0.25rem;
  font-weight: 400;
  letter-spacing: -0.022em;
  transition: color 0.25s ease;
}
.navbar-nav .nav-link.active, .navbar-nav .nav-link:focus, .navbar-nav .nav-link:hover {
  color: #1d1d1f !important;
  text-decoration: none;
}
.breadcrumb {
  background: none;
  font-size: 0.98rem;
  color: #aaa;
  margin-bottom: 0.5rem;
}
.breadcrumb-item + .breadcrumb-item::before {
  color: #ccc;
}
.main-content {
  padding-top: 88px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  background: none;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
.main-content header {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
.main-content > section > .row > .col-12 > section,
.main-content > section > .row > .col-12 > header {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
.main-content > section > .row > div.text-center {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
.main-content .article-list {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
.article-content {
  font-size: 1.18rem;
  line-height: 1.85;
  letter-spacing: 0.01em;
  color: #22223b;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
.article-content p, .article-content ol, .article-content ul {
  margin-bottom: 1.5em;
}
.article-content h2, .article-content h3 {
  margin-top: 2.2em;
  margin-bottom: 1em;
  font-weight: 700;
  color: #22223b;
}
.article-content blockquote {
  border-left: 4px solid #e0e7ef;
  background: #f8fafc;
  color: #555;
  font-size: 1.05em;
  margin: 2em 0;
  padding: 1em 1.5em;
  border-radius: 0.5em;
}
.article-content code {
  background: #f3f4f6;
  color: #b91c1c;
  border-radius: 0.3em;
  padding: 0.1em 0.4em;
  font-size: 0.98em;
}
.article-content img {
  max-width: 100%;
  border-radius: 1em;
  margin: 2em 0;
  display: block;
}
.article-content ol, .article-content ul {
  padding-left: 1.5em;
}
.article-content li {
  margin-bottom: 0.5em;
}
.article-content a {
  color: #2563eb;
  text-decoration: underline;
  transition: color 0.15s;
}
.article-content a:hover {
  color: #1e40af;
}
.article-content hr {
  border: none;
  border-top: 1px solid #ececec;
  margin: 2.5em 0;
}
.article-content pre {
  background: #f3f4f6;
  border-radius: 0.5em;
  padding: 1em;
  font-size: 1em;
  overflow-x: auto;
  margin: 2em 0;
}
.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 2em 0;
}
.article-content th, .article-content td {
  border: 1px solid #ececec;
  padding: 0.7em 1em;
  text-align: left;
}
/* Apple Store風格卡片設計 */
.card, .card-body, .card-title, .card-text, .card-icon {
  border: none !important;
  border-radius: 18px !important;
  box-shadow: none !important;
  background: #fff !important;
  color: #1d1d1f;
  margin-bottom: 0;
}

.card-body {
  padding: 1.5rem !important;
}
.card {
  margin-bottom: 2.5rem;
  min-height: unset;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid #e5e5e7 !important;
  overflow: hidden;
}
.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06) !important;
  border-color: #d1d1d6 !important;
}
.card-icon {
  font-size: 3rem;
  color: #1d1d1f;
  margin-bottom: 1rem;
  text-align: center;
  width: 100%;
  padding-top: 1.5rem;
}
.card-title {
  font-size: 1.1875rem;
  font-weight: 600;
  color: #1d1d1f;
  margin-bottom: 0.5rem;
  text-align: center;
  letter-spacing: -0.022em;
  line-height: 1.21053;
}
.card-text {
  color: #6e6e73;
  text-align: center;
  font-size: 1.0625rem;
  line-height: 1.47059;
  letter-spacing: -0.022em;
}
.card .btn-primary {
  border-radius: 8px !important;
  margin: 0;
  padding: 0.625rem 1.5rem;
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

/* 分類標籤樣式 */
.card .badge {
  font-size: 0.65rem !important;
  padding: 0.25em 0.6em;
  border-radius: 6px;
  font-weight: 400;
  letter-spacing: 0.01em;
}

/* 分類篩選按鈕 */
.category-filter-btn {
  border-radius: 20px !important;
  font-size: 0.8rem;
  font-weight: 400;
  padding: 0.4rem 0.8rem;
  transition: all 0.2s ease;
  border: 1px solid #d1d1d6;
  background: #fff;
  color: #6e6e73;
}

.category-filter-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(29, 29, 31, 0.1);
  background: #f5f5f7;
  color: #1d1d1f;
  border-color: #a1a1a6;
}

.category-filter-btn.btn-primary {
  background: #1d1d1f !important;
  color: #fff !important;
  border-color: #1d1d1f !important;
}

/* 工具卡片專用樣式 */
.tool-card {
  border: 1px solid #e5e5e7 !important;
  border-radius: 12px !important;
  transition: all 0.2s ease;
  margin-bottom: 1rem;
  min-height: 120px;
}

.tool-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05) !important;
  border-color: #d1d1d6 !important;
}

.tool-icon {
  font-size: 2rem;
  line-height: 1;
}

.tool-title {
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 0.5rem;
}

.tool-description {
  font-size: 0.75rem;
  line-height: 1.3;
  color: #8e8e93;
}

.tool-categories .badge {
  font-size: 0.6rem;
  padding: 0.2em 0.5em;
  border-radius: 4px;
  background: #f2f2f7 !important;
  color: #8e8e93 !important;
  border: none;
}

/* 手機版優化 */
@media (max-width: 575.98px) {
  .tool-card {
    min-height: 100px;
  }

  .tool-icon {
    font-size: 1.5rem;
  }

  .tool-title {
    font-size: 0.8rem;
  }

  .category-filter-btn {
    font-size: 0.7rem;
    padding: 0.3rem 0.6rem;
  }
}
.btn-primary {
  background: #1d1d1f !important;
  border: none !important;
  border-radius: 8px;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: all 0.2s ease;
  box-shadow: none;
  color: #ffffff !important;
}
.btn-primary:hover {
  background: #2d2d2f !important;
  color: #ffffff !important;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(29, 29, 31, 0.2);
}
.btn-primary:focus, .btn-primary:active, .btn-primary.active {
  background: #2d2d2f !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(29, 29, 31, 0.2) !important;
}
.pagination {
  margin-top: 3rem;
}
.pagination .page-item .page-link {
  border-radius: 8px;
  margin: 0 0.25rem;
  font-weight: 400;
  color: #1d1d1f;
  border: 1px solid #e5e5e7;
  background: #fff;
  transition: all 0.2s ease;
  min-width: 40px;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9375rem;
  box-shadow: none;
  letter-spacing: -0.01em;
}
.pagination .page-item.active .page-link,
.pagination .page-item .page-link:hover {
  background: #1d1d1f;
  color: #fff;
  border-color: #1d1d1f;
  transform: translateY(-1px);
}
footer {
  background: none !important;
  border: none !important;
  color: #6e6e73 !important;
  font-size: 1.0625rem;
  margin-top: auto;
  padding-top: 3rem;
  font-weight: 400;
  letter-spacing: -0.022em;
}
@media (max-width: 1199.98px) {
  /* 取消 1rem padding，改回 991.98px 以下才有 */
}
@media (max-width: 991.98px) {
  .main-content header,
  .main-content > section > .row > .col-12 > section,
  .main-content > section > .row > .col-12 > header,
  .main-content > section > .row > div.text-center,
  .main-content .article-list {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}
@media (max-width: 575.98px) {
  .article-content {
    font-size: 0.95rem;
  }
  .article-content h1 {
    font-size: 1.2rem;
  }
  .article-content h2 {
    font-size: 1.1rem;
  }
  .article-content h3 {
    font-size: 1.05rem;
  }
  .article-content p, .article-content ol, .article-content ul {
    margin-bottom: 1.25em;
  }
  .article-content li {
    margin-bottom: 0.4em;
  }
  .list-unstyled.d-flex.flex-wrap > li {
    width: 100% !important;
  }
  .container {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
  .main-content {
    padding-top: 56px;
    /* padding-left: 0.5rem;
    padding-right: 0.5rem; */
  }
  .main-content header {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
  .main-content > section > .row > .col-12 > section,
  .main-content > section > .row > .col-12 > header {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
  .main-content > section > .row > div.text-center {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
  .main-content > section > .row,
  .main-content > .row {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
  aside.col-lg-4 {
    width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 0 !important;
  }
  .sidebar-block {
    background: transparent !important;
  }
  .main-content h1,
  .main-content .display-5,
  .main-content .display-6,
  .main-content > h1,
  .main-content h2 {
    font-size: 1.35rem !important;
    line-height: 1.25 !important;
  }
  .main-content .lead {
    font-size: 0.98rem !important;
  }
  .display-5, .display-6 {
    font-size: 1.35rem !important;
    line-height: 1.25 !important;
  }
  .main-content .article-list {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
}
/* Apple Store風格側欄區塊 */
.sidebar-block {
  background: #fff;
  border-radius: 12px;
  box-shadow: none;
  border: 1px solid #e5e5e7;
  padding: 2rem 1.5rem 1.5rem 1.5rem;
  margin-bottom: 2.5rem;
  transition: all 0.2s ease;
}
.sidebar-block:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  border-color: #d1d1d6;
}
.sidebar-block h3 {
  font-weight: 600;
  color: #1d1d1f;
  font-size: 1.1875rem;
  margin-bottom: 1.25rem;
  letter-spacing: -0.022em;
  line-height: 1.21053;
}
.sidebar-block ul {
  margin-bottom: 0;
  padding-left: 0;
}
.sidebar-block ul li {
  margin-bottom: 0.7em;
  line-height: 1.7;
}
.sidebar-block ul li:last-child {
  margin-bottom: 0;
}
.sidebar-block ul li a {
  color: #1d1d1f;
  text-decoration: underline;
  text-decoration-color: #d1d1d6;
  text-underline-offset: 2px;
  font-size: 1.0625rem;
  transition: all 0.2s ease;
  letter-spacing: -0.022em;
}
.sidebar-block ul li a:hover {
  color: #2d2d2f;
  text-decoration-color: #1d1d1f;
  background: none;
}
.sidebar-block span, .sidebar-block p {
  color: #6e6e73;
  font-size: 1.0625rem;
  line-height: 1.47059;
  margin-bottom: 0.75em;
  display: block;
  letter-spacing: -0.022em;
}
.sidebar-block img {
  border-radius: 12px;
  margin-top: 0.75em;
  margin-bottom: 0.75em;
  max-width: 100%;
  height: auto;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* Apple Store風格標題和Hero區塊 */
h1, .display-5, .display-6 {
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.022em;
  line-height: 1.05;
}

.lead {
  color: #6e6e73;
  font-size: 1.3125rem;
  line-height: 1.381;
  letter-spacing: -0.022em;
  font-weight: 400;
}

/* 優化文章內容樣式 */
.article-content {
  font-size: 1.0625rem;
  line-height: 1.47059;
  letter-spacing: -0.022em;
  color: #1d1d1f;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.article-content h2, .article-content h3 {
  margin-top: 2.5em;
  margin-bottom: 1em;
  font-weight: 600;
  color: #1d1d1f;
  letter-spacing: -0.022em;
}

.article-content a {
  color: #1d1d1f;
  text-decoration: underline;
  text-decoration-color: #d1d1d6;
  text-underline-offset: 2px;
  transition: all 0.2s ease;
}
.article-content a:hover {
  color: #2d2d2f;
  text-decoration-color: #1d1d1f;
}
@media (min-width: 992px) {
  .main-content .row > aside {
    /* padding-top: 72px; */
  }
}

/* 文章卡片樣式 */
.article-card {
  border: 1px solid #e5e5e7 !important;
  border-radius: 12px !important;
  transition: all 0.2s ease;
  min-height: 200px;
  background: #fff !important;
}

.article-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05) !important;
  border-color: #d1d1d6 !important;
}

.article-meta {
  color: #8e8e93;
  font-size: 0.8rem;
  font-weight: 400;
}

.article-card .card-title {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 0.75rem;
  color: #1d1d1f !important;
  letter-spacing: -0.022em;
}

.article-card .card-text {
  font-size: 0.9rem;
  line-height: 1.4;
  color: #6e6e73;
  letter-spacing: -0.022em;
}

/* 響應式調整 */
@media (max-width: 991.98px) {
  .article-card {
    min-height: 180px;
  }
}

@media (max-width: 575.98px) {
  .article-card {
    min-height: 160px;
  }

  .article-card .card-title {
    font-size: 0.95rem;
  }

  .article-card .card-text {
    font-size: 0.85rem;
  }

  .article-meta {
    font-size: 0.75rem;
  }
}

/* ========================================
   Medium 風格文章卡片樣式
   ======================================== */

.medium-article-card {
  padding: 1.5rem 0;
  border-bottom: 1px solid rgba(230, 230, 230, 1);
  transition: background-color 0.2s ease;
}

.medium-article-card:hover {
  background-color: rgba(0, 0, 0, 0.01);
}

.medium-article-card:last-child {
  border-bottom: none;
}

/* 分類標籤 */
.medium-category {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #1a8917;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

/* 卡片標題 */
.medium-card-title {
  font-family: sohne, "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 1.375rem;
  font-weight: 700;
  color: #292929;
  line-height: 1.3;
  letter-spacing: -0.011em;
  transition: color 0.2s ease;
}

.medium-article-card:hover .medium-card-title {
  color: #1a1a1a;
}

/* 卡片摘要 */
.medium-card-excerpt {
  font-family: charter, Georgia, Cambria, "Times New Roman", Times, serif;
  font-size: 1rem;
  color: #757575;
  line-height: 1.5;
  letter-spacing: -0.003em;
}

/* 卡片 Meta 資訊 */
.medium-meta {
  font-size: 0.8125rem;
  color: #757575;
}

.medium-author {
  font-weight: 500;
  color: #292929;
}

.medium-dot {
  font-size: 0.5rem;
  color: #757575;
}

/* 卡片圖片 */
.medium-card-image {
  width: 200px;
  height: 134px;
}

.medium-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 響應式調整 */
@media (max-width: 767.98px) {
  .medium-article-card {
    padding: 1.25rem 0;
  }

  .medium-card-title {
    font-size: 1.125rem;
    line-height: 1.35;
  }

  .medium-card-image {
    width: 100%;
    height: 180px;
    margin-bottom: 0.5rem;
  }

  .medium-meta {
    font-size: 0.75rem;
  }
}

@media (min-width: 768px) {
  .medium-card-image {
    width: 200px;
    min-width: 200px;
    height: 134px;
  }
}
