/*
Theme Name: Blocksy Child
Theme URI: https://creativethemes.com/blocksy/
Description: Blocksy Child Theme
Author: Your Name
Author URI: https://creativethemes.com
Template: blocksy
Version: 1.0.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: blocksy-child
*/

@font-face {
  font-family: "GenYoMin TW";
  src: url("./fonts/GenYoMin2TW-EL.otf") format("opentype");
  font-weight: 200;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "GenYoMin TW";
  src: url("./fonts/GenYoMin2TW-L.otf") format("opentype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "GenYoMin TW";
  src: url("./fonts/GenYoMin2TW-R.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "GenYoMin TW";
  src: url("./fonts/GenYoMin2TW-M.otf") format("opentype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "GenYoMin TW";
  src: url("./fonts/GenYoMin2TW-SB.otf") format("opentype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "GenYoMin TW";
  src: url("./fonts/GenYoMin2TW-B.otf") format("opentype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "GenYoMin TW";
  src: url("./fonts/GenYoMin2TW-H.otf") format("opentype");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

body,
body * {
  font-family: "GenYoMin TW" !important;
}

/* ========================================
   PORTFOLIO ARCHIVE STYLES
   ======================================== */

/* Portfolio Archive Container */
.portfolio-archive-container {
  background: white;
  width: 100%;
  margin: 0 auto;
  padding: 1px 0;
}

/* Portfolio Header Section */
.portfolio-header-section {
  position: relative;
  height: 114px;
  max-width: 1440px;
  margin: 80px auto 60px;
}

.portfolio-title-wrapper {
  display: flex;
  align-items: center;
  gap: 32px;
  color: #404040;
  width: fit-content;
  position: relative;
  padding-bottom: 10px;
  padding-left: 32px;
}
.portfolio-title-wrapper::before {
  content: "";
  position: absolute;
  top: 50%;
  right: -50px;
  width: 982px;
  height: 114px;
  background-image: url("/wp-content/themes/blocksy-child/title-border-white.png");
  background-size: contain;
  background-position: right;
  background-repeat: no-repeat;
  transform: translateY(-50%);
}

.portfolio-title-english {
  font-family: "Kalnia", serif !important;
  font-size: 80px;
  font-weight: 400;
  line-height: 1.2;
  text-transform: uppercase;
  margin: 0;
}

.portfolio-title-chinese {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 3.2px;
}

.portfolio-title-chinese .subtitle {
  color: #848484;
}

/* Portfolio Grid */
.portfolio-grid {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 260px;
  display: grid;
  grid-template-columns: repeat(4, 332px);
  gap: 24px;
  margin-bottom: 60px;
}

@media (max-width: 1920px) {
  .portfolio-grid {
    padding: 0 60px;
    grid-template-columns: repeat(4, 1fr);
    max-width: 1400px;
  }
}

@media (max-width: 1400px) {
  .portfolio-grid {
    grid-template-columns: repeat(3, 1fr);
    padding: 0 40px;
  }
}

@media (max-width: 1024px) {
  .portfolio-grid {
    grid-template-columns: repeat(2, 1fr);
    padding: 0 30px;
  }
}

@media (max-width: 640px) {
  .portfolio-grid {
    grid-template-columns: 1fr;
    padding: 0 20px;
  }
}

/* Portfolio Item */
.portfolio-item {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.portfolio-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.portfolio-image {
  width: 100%;
  height: 214px;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}

.portfolio-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.portfolio-item:hover .portfolio-image img {
  transform: scale(1.05);
}

.placeholder-image {
  width: 100%;
  height: 100%;
  background: #e0e0e0;
}

.portfolio-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.portfolio-title {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 4px;
  color: #404040;
  margin: 0;
}

.portfolio-item:hover .portfolio-title {
  color: #000;
}

.portfolio-meta {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.4px;
  color: #848484;
}

/* Responsive Typography */
@media (max-width: 768px) {
  .portfolio-title-english {
    font-size: 60px;
  }

  .portfolio-title-chinese {
    font-size: 14px;
  }

  .portfolio-header-section {
    margin: 40px auto 40px;
  }
}

@media (max-width: 480px) {
  .portfolio-title-english {
    font-size: 40px;
  }

  .portfolio-title {
    font-size: 18px;
    letter-spacing: 3.6px;
  }

  .portfolio-meta {
    font-size: 12px;
  }
}
#wpadminbar .ab-icon,
#wpadminbar .ab-item:before,
#wpadminbar > #wp-toolbar > #wp-admin-bar-root-default .ab-icon,
.wp-admin-bar-arrow {
  font-family: dashicons !important;
}

/* Blog Archive Styles */
.blog-archive-container {
  background: white;
  width: 100%;
  margin: 0 auto;
  padding: 1px 0;
}

/* Blog Header Section */
.blog-header-section {
  position: relative;
  max-width: 1400px;
  margin: 80px auto 60px;
  display: flex;
  justify-content: space-between;
}

.blog-title-wrapper {
  display: flex;
  align-items: center;
  gap: 32px;
  color: #404040;
  position: relative;
  width: fit-content;
  height: 114px;
  padding-left: 32px;
}
.blog-title-wrapper::before {
  content: "";
  position: absolute;
  top: 5px;
  right: -50px;
  width: 982px;
  height: 114px;
  background-image: url("/wp-content/themes/blocksy-child/title-border-white.png");
  background-size: contain;
  background-position: right;
  background-repeat: no-repeat;
}

.blog-title-english {
  font-family: "Kalnia", serif !important;
  font-size: 80px;
  font-weight: 400;
  line-height: 1.2;
  text-transform: uppercase;
}

.blog-title-chinese {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 3.2px;
}

.blog-title-chinese .subtitle {
  color: #848484;
}

/* Category Filter */
.category-filter {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: center;
}

.category-button {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 20px;
  border: 1px solid #404040;
  border-radius: 40px;
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 3.2px;
  color: #404040;
  background: transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  white-space: nowrap;
}

.category-button:hover {
  background: #eeeeee;
  color: #404040;
}

.category-button.active {
  background: #404040;
  color: white;
}

/* Blog Grid */
.blog-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 332px);
  gap: 24px;
  margin-bottom: 60px;
}

@media (max-width: 1920px) {
  .blog-grid {
    padding: 0 60px;
    grid-template-columns: repeat(4, 1fr);
    max-width: 1400px;
  }
}

@media (max-width: 1400px) {
  .blog-grid {
    grid-template-columns: repeat(3, 1fr);
    padding: 0 40px;
  }
}

@media (max-width: 1024px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
    padding: 0 30px;
  }
}

@media (max-width: 640px) {
  .blog-grid {
    grid-template-columns: 1fr;
    padding: 0 20px;
  }
}

/* Blog Post Card */
.blog-post-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.blog-post-image {
  width: 100%;
  height: 332px;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
}

.blog-post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.blog-post-card:hover .blog-post-image img {
  transform: scale(1.05);
}

.blog-post-content {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.blog-post-meta {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.4px;
  color: #848484;
}

.blog-post-title {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 3.2px;
  color: #404040;
  text-decoration: none;
}

/* Pagination */
.blog-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-bottom: 80px;
}

.page-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 10px;
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.4px;
  color: #404040;
  background: transparent;
  border: none;
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
}

.page-number:hover {
  background: #e0e0e0;
}

.page-number.current {
  background: #404040;
  color: white;
}

.page-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  cursor: pointer;
}

.page-arrow svg {
  width: 8px;
  height: 14px;
}

.page-arrow.next {
  transform: rotate(180deg);
}

/* Responsive Typography */
@media (max-width: 768px) {
  .blog-title-english {
    font-size: 60px;
  }

  .blog-title-chinese {
    font-size: 14px;
  }

  .blog-header-section {
    margin: 40px auto 40px;
  }
}

@media (max-width: 480px) {
  .blog-title-english {
    font-size: 40px;
  }

  .category-filter {
    flex-wrap: wrap;
  }
}

/* ========================================
   SINGLE BLOG POST STYLES
   ======================================== */

/* Single Post Banner */
.single-post-banner {
  position: relative;
  height: 268px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #404040;
}

.banner-background {
  position: absolute;
  inset: 0;
  background: #404040;
  z-index: 1;
}

.banner-background::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAwIiBoZWlnaHQ9IjEwMCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZGVmcz48cGF0dGVybiBpZD0iZ3J1bmdlIiBwYXR0ZXJuVW5pdHM9InVzZXJTcGFjZU9uVXNlIiB3aWR0aD0iMTAwIiBoZWlnaHQ9IjEwMCI+PHJlY3Qgd2lkdGg9IjEwMCIgaGVpZ2h0PSIxMDAiIGZpbGw9IiM0MDQwNDAiLz48L3BhdHRlcm4+PC9kZWZzPjxyZWN0IHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3J1bmdlKSIvPjwvc3ZnPg==");
  opacity: 0.5;
}

.banner-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 838px;
  padding: 0 40px;
}

.single-post-header {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-start;
  justify-content: center;
}

.single-post-title {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 32px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 6.4px;
  color: white;
  margin: 0;
  white-space: pre-wrap;
}

.single-post-meta-top {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.4px;
  color: rgba(255, 255, 255, 0.5);
}

/* Single Post Content Wrapper */
.single-post-content-wrapper {
  max-width: 926px;
  margin: 0 auto;
  padding: 0 40px;
  position: relative;
}

/* Excerpt Box (前情提要) */
.single-post-excerpt-box {
  position: relative;
  margin-top: -100px;
  margin-bottom: 80px;
  padding: 50px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(15px);
  border: 1px solid white;
  border-radius: 20px;
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 18px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.8px;
  color: #404040;
  z-index: 10;
}

/* Featured Image */
.single-post-featured-image {
  margin-bottom: 80px;
  border-radius: 8px;
  overflow: hidden;
}

.single-post-featured-image img {
  width: 100%;
  height: auto;
  max-height: 580px;
  object-fit: cover;
  display: block;
}

/* Main Content */
.single-post-content {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  color: #404040;
  line-height: 1.6;
  margin-bottom: 80px;
}

.single-post-content h1,
.single-post-content h2,
.single-post-content h3,
.single-post-content h4,
.single-post-content h5,
.single-post-content h6 {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-weight: 700;
  color: #404040;
  margin-bottom: 20px;
  margin-top: 50px;
}

.single-post-content h2 {
  line-height: 1.8;
  letter-spacing: 4.8px;
}

.single-post-content h3 {
  line-height: 1.6;
  letter-spacing: 4px;
}

.single-post-content h4 {
  line-height: 1.6;
  letter-spacing: 3.6px;
}

.single-post-content p {
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.8px;
  color: #848484;
  margin-bottom: 20px;
}

.single-post-content ul,
.single-post-content ol {
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.8px;
  color: #848484;
  margin-bottom: 20px;
  padding-left: 27px;
}

.single-post-content li {
  margin-bottom: 12px;
}

.single-post-content img {
  width: 100%;
  height: auto;
  max-height: 500px;
  object-fit: cover;
  border-radius: 8px;
  margin: 30px 0;
}

.single-post-content a {
  color: #404040;
  text-decoration: underline;
}

.single-post-content a:hover {
  color: #000;
}

/* Horizontal Line Divider */
.single-post-content hr {
  border: none;
  border-top: 1px solid #e0e0e0;
  margin: 50px 0;
}

/* Tags Section */
.single-post-tags {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 80px;
}

.post-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 20px;
  border: 1px solid #404040;
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 3.2px;
  color: #404040;
  text-decoration: none;
  transition: all 0.3s ease;
}

.post-tag:hover {
  background: #404040;
  color: white;
}

/* Back to Blog Button */
.back-to-blog-wrapper {
  max-width: 926px;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  justify-content: flex-end;
  margin-bottom: 80px;
}

.back-to-blog-button {
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 3.2px;
  color: #404040;
  text-decoration: none;
  transition: all 0.3s ease;
}

.back-to-blog-button:hover {
  color: #000;
}

.back-to-blog-button svg {
  width: 50px;
  height: 29px;
  transition: transform 0.3s ease;
}

.back-to-blog-button:hover svg {
  transform: translateX(5px);
}

/* Recommended Posts Section */
.recommended-posts-section {
  background: white;
  padding: 80px 0;
  margin-top: 80px;
}

.recommended-posts-header {
  position: relative;
  max-width: 976px;
  height: 114px;
  margin: 0 auto 80px;
}

.recommended-title-wrapper {
  display: flex;
  align-items: center;
  gap: 32px;
  color: #404040;
  padding-left: 292px;
}

.recommended-title-english {
  font-family: "Kalnia", serif !important;
  font-size: 80px;
  font-weight: 400;
  line-height: 1.2;
  text-transform: uppercase;
  margin: 0;
}

.recommended-title-chinese {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 3.2px;
}

.recommended-title-chinese .subtitle {
  color: #848484;
}

/* Recommended Posts Grid */
.recommended-posts-grid {
  max-width: 1164px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 372px);
  gap: 24px;
  justify-content: center;
  padding: 0 40px;
}

.recommended-post-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.recommended-post-image {
  width: 100%;
  height: 372px;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}

.recommended-post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.recommended-post-card:hover .recommended-post-image img {
  transform: scale(1.05);
}

.recommended-post-content {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.recommended-post-meta {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.4px;
  color: #848484;
}

.recommended-post-title {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 3.2px;
  color: #404040;
  text-decoration: none;
}

.recommended-post-card:hover .recommended-post-title {
  color: #000;
}

/* Responsive Styles for Single Post */
@media (max-width: 1200px) {
  .recommended-posts-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .recommended-title-wrapper {
    padding-left: 100px;
  }
}

@media (max-width: 1024px) {
  .recommended-posts-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .recommended-title-english {
    font-size: 60px;
  }

  .recommended-title-wrapper {
    padding-left: 40px;
  }
}

@media (max-width: 768px) {
  .single-post-title {
    font-size: 24px;
    letter-spacing: 4.8px;
  }

  .single-post-banner {
    height: 200px;
  }

  .single-post-excerpt-box {
    padding: 30px;
    margin-top: -60px;
    font-size: 16px;
  }

  .single-post-content h2 {
    font-size: 20px;
  }

  .single-post-content h3 {
    font-size: 18px;
  }

  .single-post-content p,
  .single-post-content ul,
  .single-post-content ol {
    font-size: 16px;
  }

  .recommended-title-english {
    font-size: 48px;
  }

  .recommended-title-wrapper {
    padding-left: 20px;
    gap: 20px;
  }

  .recommended-posts-grid {
    grid-template-columns: 1fr;
    padding: 0 20px;
  }
}

@media (max-width: 480px) {
  .single-post-title {
    font-size: 20px;
    letter-spacing: 3.2px;
  }

  .single-post-content-wrapper {
    padding: 0 20px;
  }

  .back-to-blog-wrapper {
    padding: 0 20px;
  }

  .recommended-title-english {
    font-size: 36px;
  }
}

/* ========================================
   FOOTER STYLES
   ======================================== */

.site-footer {
  background: #404040;
}

.footer-container {
  display: flex;
  justify-content: center;
}

.footer-logo-container {
  width: 35%;
  background: #f5f5f5;
  padding: 60px 0;
  display: flex;
  justify-content: center;
  position: relative;
}

.footer-logo-container::before {
  content: "";
  position: absolute;
  right: -60px;
  top: 0;
  width: 120px;
  height: 100%;
  background: #f5f5f5;
  border-left: 3px solid #f5f5f5;
  transform: skewX(-10deg);
}

.footer-logo-container img {
  width: 108px;
  object-fit: contain;
}
.footer-content-container {
  width: 65%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  padding: 40px 0;
}

.footer-content-container::before {
  content: "";
  position: absolute;
  left: 44px;
  top: 0;
  width: 5px;
  height: 100%;
  background: #404040;
  transform: skewX(-10deg);
}
.footer-content-container::after {
  content: "";
  position: absolute;
  left: 40px;
  top: 0;
  width: 1px;
  height: 100%;
  background: #404040;
  transform: skewX(-10deg);
}

/* Footer Navigation */

.footer-menu {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 40px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

.footer-menu li {
  margin: 0;
}

.footer-menu a {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 1.6px;
  color: rgb(255, 255, 255);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-menu a:hover {
  color: white;
}

.footer-menu .sub-menu {
  padding-left: 0;
  padding-top: 14px;
  padding-bottom: 33px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.footer-menu .sub-menu a {
  color: rgba(255, 255, 255, 0.5);
}

/* Footer Bottom */
.footer-bottom {
  text-align: center;
  display: flex;
  gap: 30px;
}

.footer-info {
  display: flex;
  gap: 24px;
}

.footer-info img {
  width: 24px;
  margin-right: 8px;
}

.footer-info a {
  display: flex;
  align-items: center;
  font-size: 12px;
  color: white;
  letter-spacing: 1.2px;
}

.footer-icons {
  display: flex;
  gap: 8px;
}
.footer-icons img {
  width: 40px;
}

.footer-copyright {
  font-family: "GenYoMin TW", "Microsoft JhengHei", sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
  letter-spacing: 1.4px;
  color: rgba(255, 255, 255, 0.5);
  margin: 0;
}

/* Responsive Footer Styles */
@media (min-width: 1440px) and (max-width: 1919px) {
  .footer-logo-container {
    /* 從 358px (1440px) 線性增加到 672px (1920px) */
    width: calc(-584px + 65.4vw);
    flex-shrink: 0;
  }

  .footer-content-container {
    width: auto;
    flex: 1;
    align-items: flex-start;
    padding-left: 120px;
  }
}

@media (min-width: 1025px) and (max-width: 1439px) {
  .footer-logo-container {
    /* 從 308px (1025px) 到 358px (1440px)，只縮左邊 padding */
    /* 左 100px (min) → 150px，右固定 100px */
    width: calc(196px + 11.2vw);
    flex-shrink: 0;
    justify-content: flex-end;
    padding-right: 100px;
  }

  .footer-content-container {
    width: auto;
    flex: 1;
    align-items: flex-start;
    padding-left: 120px;
    /* 右 padding 從 120px (1440px) 縮到 100px (1025px) */
    padding-right: calc(50px + 4.8vw);
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-end;
    gap: 16px;
  }

  .footer-icons {
    order: -1;
  }
}

/* Mobile Footer Header - 預設隱藏 */
.footer-mobile-header {
  display: none;
}

@media (max-width: 1024px) {
  /* 顯示 Mobile Header */
  .footer-mobile-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 60px 20px 40px;
  }

  .footer-mobile-logo {
    width: 200px;
    height: auto;
  }

  /* 隱藏桌面版 Logo 區塊 */
  .footer-logo-container {
    display: none;
  }

  /* Footer Container 調整 */
  .footer-container {
    flex-direction: column;
  }

  .footer-content-container {
    width: 100%;
    padding: 0 20px 40px;
  }

  .footer-content-container::before,
  .footer-content-container::after {
    display: none;
  }

  /* 導航選單 - 垂直排列 + 分隔線 */
  .footer-navigation {
    width: 100%;
  }

  .footer-menu {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: 100%;
  }

  .footer-menu > li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  }

  .footer-menu > li:first-child {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
  }

  .footer-menu > li > a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    font-size: 14px;
    letter-spacing: 2px;
  }

  /* 有子選單的項目顯示箭頭 */
  .footer-menu > li.menu-item-has-children > a::after {
    content: "";
    width: 10px;
    height: 10px;
    border-right: 2px solid rgba(255, 255, 255, 0.5);
    border-bottom: 2px solid rgba(255, 255, 255, 0.5);
    transform: rotate(45deg);
    transition: transform 0.3s ease;
  }

  /* 展開時箭頭旋轉 */
  .footer-menu > li.menu-item-has-children.is-open > a::after {
    transform: rotate(-135deg);
  }

  /* 子選單 - 預設隱藏，展開時顯示 */
  .footer-menu .sub-menu {
    display: none;
    padding: 0 0 16px 0;
  }

  .footer-menu > li.menu-item-has-children.is-open .sub-menu {
    display: flex;
  }

  .footer-menu .sub-menu a {
    padding: 8px 0;
    font-size: 13px;
  }

  /* Footer Bottom - 垂直置中排列 */
  .footer-bottom {
    flex-direction: column;
    align-items: center;
    margin-top: 40px;
    gap: 20px;
  }

  .footer-info {
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }

  .footer-info a {
    font-size: 11px;
    letter-spacing: 1px;
  }

  .footer-info img {
    width: 20px;
  }

  .footer-icons {
    gap: 6px;
  }

  .footer-icons img {
    width: 32px;
  }
}

@media (max-width: 640px) {
  .footer-bottom {
    flex-direction: column;
    align-items: center;
    gap: 30px;
  }

  .footer-info {
    align-items: center;
  }

  .footer-icons {
    align-self: center;
  }

  .blog-header-section {
    flex-direction: column;
    gap: 20px;
  }
}

/* ========================================
   POST TABLE OF CONTENTS
   ======================================== */

.post-toc {
  background: #f9f9f9;
  border: 1px solid #e0e0e0;
  border-left: 4px solid #404040;
  border-radius: 8px;
  padding: 20px 25px;
  margin-bottom: 30px;
}

.post-toc-title {
  font-size: 18px;
  font-weight: 700;
  color: #404040;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 1px solid #e0e0e0;
}

.post-toc-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.post-toc-list li {
  margin: 0;
  padding: 0;
}

.post-toc-list .toc-item {
  margin-bottom: 8px;
}

.post-toc-list .toc-item a {
  color: #404040;
  text-decoration: none;
  font-size: 16px;
  line-height: 1.6;
  display: inline-block;
  transition: color 0.3s ease;
}

.post-toc-list .toc-item a:hover {
  color: #000;
}

.post-toc-list .toc-item-h3 {
  padding-left: 20px;
  position: relative;
}

.post-toc-list .toc-item-h3 a {
  font-size: 15px;
  color: #848484;
}

.post-toc-list .toc-item-h3 a:hover {
  color: #404040;
}

/* Responsive TOC */
@media (max-width: 768px) {
  .post-toc {
    padding: 15px 20px;
    margin-bottom: 25px;
  }

  .post-toc-title {
    font-size: 16px;
    margin-bottom: 12px;
  }

  .post-toc-list .toc-item a {
    font-size: 15px;
  }

  .post-toc-list .toc-item-h3 a {
    font-size: 14px;
  }

  .post-toc-list .toc-item-h3 {
    padding-left: 15px;
  }
}
